summaryrefslogtreecommitdiff
path: root/test/files/neg/primitive-sigs-1
Commit message (Collapse)AuthorAgeFilesLines
* Another lap around the track with generic signa...Paul Phillips2011-03-023-0/+22
Another lap around the track with generic signatures. At the root of the issue reported in #4214 is our old friend (fondly remembered from the days of primitive equality) boxed/primitive unification. // scala trait T[A] { def f(): A } // the generic signature spec doesn't allow for parameterizing // on primitive types, so this cannot remain Char. However // translating it to Character, as was done, also has issues. class C extends T[Char] { def f(): Char = 'a' } // Note that neither of the signatures for f, the implementation // or the bridge method, matches the type parameter. Generic interfaces in class: T<java.lang.Character> Generic signatures: public char C.f() public java.lang.Object C.f() After this commit, primitive type parameters are translated into Object instead of the boxed type. It was martin's idea, so no review. Closes #4214.