pathTokens match {
case List("post") => ("post", "index")
case List("search") => ("search", "index")
case List() => ("home", "index")
} match {
case (controller, action) => loadController(http, controller, action)
case _ => null
}
我想要連續比賽。但有編譯錯誤。 :(斯卡拉連續比賽
(pathTokens match {
case List("post") => ("post", "index")
case List("search") => ("search", "index")
case List() => ("home", "index")
}) match {
case (controller, action) => loadController(http, controller, action)
case _ => null
}
當我裹着首場比賽parenparenthesis,它的工作確定 爲什麼我需要在這裏括號
感謝您幫助的註釋。 – drypot 2010-04-10 07:47:53