title: Empty partial function in Scala
body: <p>It seems to me like the <code>{ case ... =&gt; ... }</code> syntax for partial functions require at least one <code>case</code>:</p>
  
  <pre><code>scala&gt; val pf: PartialFunction[String, String] = { case "a" =&gt; "b" } 
  pf: PartialFunction[String,String] = &lt;function1&gt;
  
  scala&gt; val pf: PartialFunction[String, String] = { }                
  &lt;console&gt;:5: error: type mismatch;
   found   : Unit
   required: PartialFunction[String,String]
         val pf: PartialFunction[String, String] = { }
                                                   ^
  </code></pre>
  
  <p>So, what's the best way to define an "empty" partial function? Is there a better way than "manually" overriding <code>isDefinedAt</code> and <code>apply</code>?</p>