diff options
author | Lukas Rytz <lukas.rytz@gmail.com> | 2015-05-27 17:29:03 +0200 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@gmail.com> | 2015-05-28 11:42:40 +0200 |
commit | 7db3a58872593526c2cc175df633161f2ce9cccb (patch) | |
tree | 0f051049363fc48f3aba98eb676abe2362f2092d /test/files/jvm/t5471.scala | |
parent | bb302833c7bad6ff7591cdf6d10ec7ffdf683d6a (diff) | |
download | scala-7db3a58872593526c2cc175df633161f2ce9cccb.tar.gz scala-7db3a58872593526c2cc175df633161f2ce9cccb.tar.bz2 scala-7db3a58872593526c2cc175df633161f2ce9cccb.zip |
Fix illegal inlining of instructions accessing protected members
There were two issues in the new inliner that would cause a
VerifyError and an IllegalAccessError.
First, an access to a public member of package protected class C can
only be inlined if the destination class can access C. This is tested
by t7582b.
Second, an access to a protected member requires the receiver object
to be a subtype of the class where the instruction is located. So
when inlining such an access, we need to know the type of the receiver
object - which we don't have. Therefore we don't inline in this case
for now. This can be fixed once we have a type propagation analyis.
https://github.com/scala-opt/scala/issues/13.
This case is tested by t2106.
Force kmpSliceSearch test to delambdafy:inline
See discussion on https://github.com/scala/scala/pull/4505. The issue
will go away when moving to indy-lambda.
Diffstat (limited to 'test/files/jvm/t5471.scala')
0 files changed, 0 insertions, 0 deletions