Skip to content

Commit 94c8c88

Browse files
committed
Quick-fix non-idempotent code generated by pattern match
1 parent 2829889 commit 94c8c88

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

compiler/src/dotty/tools/dotc/transform/PatternMatcher.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package transform
33

44
import core._
55
import MegaPhase._
6-
import collection.mutable
6+
import scala.collection.mutable
77
import SymDenotations._, Symbols._, Contexts._, Types._, Names._, StdNames._, NameOps._
88
import ast.Trees._
99
import util.Positions._
@@ -700,7 +700,7 @@ object PatternMatcher {
700700
}
701701
val newArgs =
702702
for {
703-
(rhs, actual) <- seenVars.toList
703+
(rhs, actual) <- seenVars.toList.sortBy(_._2.toString)
704704
formal <- paramsOfLabel(plan.label).get(rhs)
705705
}
706706
yield (formal -> actual)

0 commit comments

Comments
 (0)