Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 365175

Summary: [Xtend] typing in nested switch statements doesn't work as expected
Product: [Tools] Xtend Reporter: Moritz Eysholdt <moritz.eysholdt>
Component: CoreAssignee: Project Inbox <xtend-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: dennis.huebner, sebastian.zarnekow, sven.efftinge
Version: 2.2.0   
Target Milestone: M6   
Hardware: Macintosh   
OS: Mac OS X   
Whiteboard:
Bug Depends on: 376037    
Bug Blocks:    

Description Moritz Eysholdt CLA 2011-11-30 05:31:14 EST
Example:

---
class foo  {
	def bar(Object o) {
		switch (o) {
			CharSequence:
				switch(o) {
					Comparable: {
						o.charAt(1)
						o.compareTo(o)
					}
				}
		}
	}
}
---

Within the second case-statement, I'd expect to be able to access the methods declared in interface CharSequence and in interface Comparable.

However, the reference to "o.charAt(1)" can not be resolved.
Comment 1 Dennis Huebner CLA 2013-02-14 03:52:27 EST
Works like a charm with the new type system.
Comment 2 Eclipse Webmaster CLA 2017-10-31 11:06:48 EDT
Requested via bug 522520.

-M.
Comment 3 Eclipse Webmaster CLA 2017-10-31 11:18:13 EDT
Requested via bug 522520.

-M.