Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 370011 - [Xtend] Cannot call static method on class with same (simple) name as surrounding class
Summary: [Xtend] Cannot call static method on class with same (simple) name as surroun...
Status: CLOSED WORKSFORME
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 2.2.1   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-27 16:06 EST by Sven-Torben Janus CLA
Modified: 2017-09-19 17:58 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sven-Torben Janus CLA 2012-01-27 16:06:38 EST
Build Identifier: Build Identifier: 2.2.1 (on Eclipse Version: 3.7.1 Build id: M20110909-1335)

Calling a static method on a class with full package name, gives error "Couldn't resolve reference to JvmIdentifiableElement '<ElementName'.".
As demonstrated in section "Steps to reproduce", this is especially problematic when surrounding class has the same name as class on which static method should be called.

Reproducible: Always

Steps to Reproduce:
1. Create a new Xtend file with the following contents:

package test
class Response {
	def public get() {
		javax.ws.rs.core.Response::seeOther (new java.net.URI("http://www..host.tld/")).build
	}	
}

2. Save file
Comment 1 Sebastian Zarnekow CLA 2012-01-30 03:11:25 EST
It should be 

javax::ws::rs::core::Response::seeOther

Please reopen if the problem persists.
Comment 2 Karsten Thoms CLA 2017-09-19 17:47:22 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 3 Karsten Thoms CLA 2017-09-19 17:58:30 EDT
Closing all bugs that were set to RESOLVED before Neon.0