Skip to content

Commit bcd9836

Browse files
committed
Turn optimisations for tests on again.
It turns out that when we restrict DropGoodCasts to isInstanceOf tests (as opposed to pattern-matcher generated type tests), we do not miss any error messages. Some warnings are still be omitted under optimize, not sure whether we want to fix that.
1 parent 40910d8 commit bcd9836

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

compiler/src/dotty/tools/dotc/typer/Applications.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ trait Applications extends Compatibility { self: Typer with Dynamic =>
288288

289289
def handlePositional(pnames: List[Name], args: List[Trees.Tree[T]]): List[Trees.Tree[T]] =
290290
args match {
291-
case (arg: NamedArg) :: _ =>
291+
case (arg: NamedArg @unchecked) :: _ =>
292292
val nameAssocs = for (arg @ NamedArg(name, _) <- args) yield (name, arg)
293293
handleNamed(pnames, args, nameAssocs.toMap, Set())
294294
case arg :: args1 => arg :: handlePositional(pnames.tail, args1)

compiler/test/dotty/tools/vulpix/TestConfiguration.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ object TestConfiguration {
5454

5555
val defaultUnoptimised = noCheckOptions ++ checkOptions ++ yCheckOptions ++ classPath
5656
val defaultOptimised = defaultUnoptimised :+ "-optimise"
57-
val defaultOptions = defaultUnoptimised
57+
val defaultOptions = defaultOptimised
5858
val allowDeepSubtypes = defaultOptions diff Array("-Yno-deep-subtypes")
5959
val allowDoubleBindings = defaultOptions diff Array("-Yno-double-bindings")
6060
val picklingOptions = defaultUnoptimised ++ Array(

0 commit comments

Comments
 (0)