[#1285] | project: compiler | priority: high | category: bug | |
---|---|---|---|---|
submitter | assigned to | status | date submitted | |
Sean | Burak | fixed | 2007-08-22 10:39:01.0 | |
subject | pattern matcher outer/trait problem | |||
code |
package test object Go { trait Matchers { case class Match(open : Char, close : Char) val Parens = Match('(', ')') val Braces = Match('{', '}') } trait Presentation extends Matchers { def test(what : Option[(Match,Int,Int)]) = what match { case Some(Parens,_,x)=> x case _ => 0 } } def main(args : Array[String]) : Unit = { val foo = new Presentation {} Console.println(foo.test(Some(foo.Braces,10,10))) } } |
|||
what happened | Prints 10. Note: I pulled and rebuilt this morning, so this isn't a dupe of the previous outer problem. |
|||
what expected | Should print 0. | |||
[back to overview] |
Burak edited on 2007-08-22 12:15:18.0 |
fixed in 12627 |