| [#327] | project: compiler | priority: low | category: bug | |
|---|---|---|---|---|
| submitter | assigned to | status | date submitted | |
| Burak | Sebastian | won't fix | 2004-05-05 12:11:23.0 | |
| subject | match policy bug | |||
| code |
object matchOrder {
def main( args:Array[String] ) = {
List('a','a','a','a') match {
/* here it works
case Seq( 'a'*,x @ (( 'a','a','a') | ('a','a') | 'a' )) =>
Console.println("x = "+x);
*/
case Seq( 'a'*,x @ ( 'a' | ('a','a') | ('a','a', 'a' ))) =>
Console.println("x = "+x);
case _ =>
Console.println("no match");
}
}
}
|
|||
| what happened | x = List(a) |
|||
| what expected | The "right-longest" match policy should return
x = List(a,a,a)In other words, the commented and the uncommented results should give the same result. |
|||
| [back to overview] | ||||
| Martin edited on 2007-03-08 13:00:27.0 |
| won't fix because no regexp matching anymore. |