diff options
author | Adriaan Moors <adriaan@lightbend.com> | 2016-10-04 12:48:30 -0500 |
---|---|---|
committer | Adriaan Moors <adriaan@lightbend.com> | 2016-10-04 15:48:33 -0500 |
commit | 20896646122fa82dc81f1405173b09eac37ae7cc (patch) | |
tree | 6422d91f1142c7c393eed6433700ae226d3a2157 /spec/public/scripts/highlight.pack.js | |
parent | 1f6006d0d4f8edf4db04915702f8b7e3c8ca1f5e (diff) | |
download | scala-20896646122fa82dc81f1405173b09eac37ae7cc.tar.gz scala-20896646122fa82dc81f1405173b09eac37ae7cc.tar.bz2 scala-20896646122fa82dc81f1405173b09eac37ae7cc.zip |
SI-9943 final/sealed class does not yield SAM type
Cannot subclass such a class. (Well, we could subclass a sealed
class in the same compilation unit. We ignore this for simplicity.)
This is a bit of a sneaky fix for this bug, but our hand
is pretty much forced by other constraints, in this intersection
of overload resolution involving built-in function types and SAMs,
and type inference for higher-order function literals (#5307).
Luckily, in this particular issue, the overloading clash seems
accidental. The `sealed` `<:<` class is not a SAM type as it
cannot be subclassed outside of `Predef`. For simplicity,
we don't consider where the SAM conversion occurs and exclude
all sealed classes from yielding SAM types.
Thanks to Miles for pointing out that `final` was missing in my
first iteration of this fix.
Diffstat (limited to 'spec/public/scripts/highlight.pack.js')
0 files changed, 0 insertions, 0 deletions