title: scala-ide error only classes can have declared but undefined members
body: <p>I have code like this</p>
  
  <pre><code>object API {
  
      val apiBaseUrl = "https://api.com/2/"
  
      def getUserDetails(id: String, pass: String): Map[String, String] {
          val apiRequestUrl = apiBaseUrl + "?id=" + id + "&amp;pass=" + pass
      }
  }
  </code></pre>
  
  <p>This gives me error <code>only classes can have declared but undefined members</code> for line starting with <code>def</code> and error <code>only declarations allowed here</code> for line starting with <code>val apiRequestUrl</code>. But when i change the above code to(just put an equals sign after the method signature)</p>
  
  <pre><code>object API {
  
      val apiBaseUrl = "https://api.com/2/"
  
      def getUserDetails(id: String, pass: String): Map[String, String] = {
          val apiRequestUrl = apiBaseUrl + "?id=" + id + "&amp;pass=" + pass
      }
  }
  </code></pre>
  
  <p>there is no error. Is there a difference between the above 2 definitions?</p>