diff options
author | Lukas Rytz <lukas.rytz@gmail.com> | 2016-03-08 21:20:28 +0100 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@gmail.com> | 2016-03-23 11:56:21 +0100 |
commit | e483fe26825501c175b701a662160dd0e54b035e (patch) | |
tree | ef9161418557cf69f647726af33bf3b5a8d201a6 /test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala | |
parent | 952da60a5be15ef972b521bdaf5e650f7e0a5245 (diff) | |
download | scala-e483fe26825501c175b701a662160dd0e54b035e.tar.gz scala-e483fe26825501c175b701a662160dd0e54b035e.tar.bz2 scala-e483fe26825501c175b701a662160dd0e54b035e.zip |
Inline super calls, as they are statically resolved
Ensures that mixin methods of `@inline` annotated concrete trait methods
inline the trait method.
Fixes https://github.com/scala/scala-dev/issues/86
Diffstat (limited to 'test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala')
-rw-r--r-- | test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala b/test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala index dfbedbaa25..1ce913006d 100644 --- a/test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala +++ b/test/junit/scala/tools/nsc/backend/jvm/opt/BTypesFromClassfileTest.scala @@ -67,14 +67,17 @@ class BTypesFromClassfileTest { // there's a separate InlineInfoTest. val chk1 = sameBTypes(fromSym.superClass, fromClassfile.superClass, checked) + + // was: + // val chk2 = sameBTypes(fromSym.interfaces, fromClassfile.interfaces, chk1) + // TODO: The new trait encoding emits redundant parents in the backend to avoid linkage errors in invokespecial + // Need to give this some more thought, maybe do it earlier so it is reflected in the Symbol's info, too. val fromSymInterfaces = fromSym.interfaces val fromClassFileInterfaces = fromClassfile.interfaces val (matching, other) = fromClassFileInterfaces.partition(x => fromSymInterfaces.exists(_.internalName == x.internalName)) val chk2 = sameBTypes(fromSym.interfaces, matching, chk1) for (redundant <- other) { - // TODO SD-86 The new trait encoding emits redundant parents in the backend to avoid linkage errors in invokespecial - // Need to give this some more thought, maybe do it earlier so it is reflected in the Symbol's info, too. assert(matching.exists(x => x.isSubtypeOf(redundant).orThrow), redundant) } |