| Summary: | [Xtend/Xbase] Wrong use of local type parameter | ||
|---|---|---|---|
| Product: | [Tools] Xtend | Reporter: | Sven Efftinge <sven.efftinge> |
| Component: | Core | Assignee: | Project Inbox <xtend-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | dennis.huebner, sebastian.zarnekow |
| Version: | 2.2.0 | Flags: | sven.efftinge:
kepler+
|
| Target Milestone: | M6 | ||
| Hardware: | PC | ||
| OS: | Mac OS X - Carbon (unsup.) | ||
| Whiteboard: | |||
| Bug Depends on: | 376037 | ||
| Bug Blocks: | |||
Works with the new TS Requested via bug 522520. -M. Requested via bug 522520. -M. |
def <T> T foo(Class<T> clazz) { val x = typeof(String).foo return null } compiles to invalid Java code: public <T extends Object> T foo(final Class<T> clazz) { T _foo = this.<String>foo(java.lang.String.class); final T x = _foo; return null; } _foo should be of type String