blob: d531c6b34304d83793a218664c6b95ab6d116f4f (
plain) (
tree)
|
|
object Test{
def foo(a: Int) = a match {
case 5 => "Five!"
case 42 => "The answer."
}
def bar(a: (Int, Int)) = a match {
case (5, 5) => "Two fives!"
case (42, 21) => "The answer and a half."
}
def baz(a: (Boolean, Boolean)) = a match {
case (true, false) => "tf"
case (false, true) => "ft"
}
}
|