| Summary: | Type conformance not checked | ||
|---|---|---|---|
| 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.3.0 | Flags: | sven.efftinge:
kepler+
|
| Target Milestone: | M6 | ||
| Hardware: | PC | ||
| OS: | Mac OS X - Carbon (unsup.) | ||
| Whiteboard: | |||
| Bug Depends on: | 376037 | ||
| Bug Blocks: | |||
IterableExtensions#forEach returns void thus I'd expect an error marker on the invocation of println Fixed in the meanwhile. Error marker says: Incompatible types. Expected Object but was void |
Given the following Xtend code: class XtendClass { @Test def void testMethod() { println(newArrayList('foo','bar','baz').toUpperCase) } def toUpperCase(Collection<String> allStrings) { allStrings.forEach[toUpperCase] } } the compiler generates : @Test public void testMethod() { ArrayList<String> _newArrayList = CollectionLiterals.<String>newArrayList("foo", "bar", "baz"); this.toUpperCase(_newArrayList); InputOutput.<void>println(null); } note 'void' is used as type parameter.