type-diagnostics.scala:4: error: type mismatch; found : Set[String] (in scala.collection) required: Set[String] (in scala.collection.immutable) def f = Calculator("Hello", binding.keySet: collection.Set[String]) ^ type-diagnostics.scala:13: error: type mismatch; found : List[a(in method f2)] required: List[a(in method f1)] y match { case y1: List[a] => f3(x, y1) } ^ type-diagnostics.scala:17: error: type mismatch; found : String(in method f2) required: java.lang.String def f2[String](s: String) = strings(List(s)) ^ type-diagnostics.scala:21: error: missing parameter type for expanded function The argument types of an anonymous function must be fully known. (SLS 8.5) Expected type was: ? val f = { case 5 => 10 } ^ four errors found