summaryrefslogtreecommitdiff
path: root/src/compiler
diff options
context:
space:
mode:
authorBurak Emir <emir@epfl.ch>2006-12-10 15:08:55 +0000
committerBurak Emir <emir@epfl.ch>2006-12-10 15:08:55 +0000
commit593deb5d5004162a35a98277900d2baeb40c09c8 (patch)
tree38a14fa9db389d2feabfd6910b611f29730b3326 /src/compiler
parente794df0beb2f6c72bbfe5cfe1a9ab4de603280b1 (diff)
downloadscala-593deb5d5004162a35a98277900d2baeb40c09c8.tar.gz
scala-593deb5d5004162a35a98277900d2baeb40c09c8.tar.bz2
scala-593deb5d5004162a35a98277900d2baeb40c09c8.zip
fixed bug when matching chars and int
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/scala/tools/nsc/matching/PatternMatchers.scala14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/compiler/scala/tools/nsc/matching/PatternMatchers.scala b/src/compiler/scala/tools/nsc/matching/PatternMatchers.scala
index f704703490..45ff87c4de 100644
--- a/src/compiler/scala/tools/nsc/matching/PatternMatchers.scala
+++ b/src/compiler/scala/tools/nsc/matching/PatternMatchers.scala
@@ -918,6 +918,20 @@ print()
node.and.bodyToTree(),
mappings);
node = node.or;
+
+ case ConstantPat( value: Char )=>
+ mappings = insert1(value.toInt,node.and.bodyToTree(),mappings);
+ node = node.or;
+
+/*
+ case ConstantPat( value: Byte )=>
+ mappings = insert1(value.toInt,node.and.bodyToTree(),mappings);
+ node = node.or;
+
+ case ConstantPat( value: Short )=>
+ mappings = insert1(value.toInt,node.and.bodyToTree(),mappings);
+ node = node.or;
+*/ // these correct?
}
}
patNode = patNode.nextH()