diff options
author | odersky <odersky@gmail.com> | 2017-03-16 17:20:48 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-16 17:20:48 +0100 |
commit | ef55ec03e8e91402c33b09993906ec7ac34ae9b5 (patch) | |
tree | c09847b545234d56b1e91457cd5f82f5220af746 | |
parent | ac51f06cd10e6a1ac5efb2923f0f786d1b878061 (diff) | |
parent | ed7aec86d2414ca681282f16f61ec4998c1defea (diff) | |
download | dotty-ef55ec03e8e91402c33b09993906ec7ac34ae9b5.tar.gz dotty-ef55ec03e8e91402c33b09993906ec7ac34ae9b5.tar.bz2 dotty-ef55ec03e8e91402c33b09993906ec7ac34ae9b5.zip |
Merge pull request #2108 from dotty-staging/fix-match-in-mergeCompanionDefs
Make pattern match exhaustive for mergeCompanionDefs.
-rw-r--r-- | compiler/src/dotty/tools/dotc/typer/Namer.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/src/dotty/tools/dotc/typer/Namer.scala b/compiler/src/dotty/tools/dotc/typer/Namer.scala index f2ad1f7c9..2cefc52a0 100644 --- a/compiler/src/dotty/tools/dotc/typer/Namer.scala +++ b/compiler/src/dotty/tools/dotc/typer/Namer.scala @@ -537,7 +537,7 @@ class Namer { typer: Typer => case Thicket(trees) => // companion object always expands to thickets trees.map { case mcls @ TypeDef(name, impl: Template) if valid(mcls) => - moduleClsDef.get(name) match { + (moduleClsDef.get(name): @unchecked) match { case Some((stat1, mcls1@TypeDef(_, impl1: Template))) => mergeIfSynthetic(stat, mcls, stat1, mcls1) mergeIfSynthetic(stat1, mcls1, stat, mcls) |