title: Groovy method call syntax
body: <p>A tutorial <a href="http://groovy.codehaus.org/Statements" rel="noreferrer">here</a> says:</p>
  
  <blockquote>
    <p>Method calls in Groovy can omit the parenthesis if there is at least one parameter and there is no ambiguity.</p>
  </blockquote>
  
  <p>This works:</p>
  
  <pre><code>static method1(def val1)
  {
      "Statement.method1 : $val1"
  }
  
  def method1retval = method1 30; 
  println (method1retval);  //Statement.method1 : 30
  </code></pre>
  
  <p>But when I add another parameter to the method:</p>
  
  <pre><code>static method1(def val1, def val2)
  {
      "Statement.method1 : $val1 $val2"
  }
  def method1retval = method1 30 "20";
  println (method1retval);
  </code></pre>
  
  <p>It gives error</p>
  
  <pre><code>Exception in thread "main" groovy.lang.MissingMethodException: No signature of method: static Statements.method1() is applicable for argument types: (java.lang.Integer) values: [30]
  Possible solutions: method1(int, java.lang.String)
  </code></pre>
  
  <p><strong>Q.</strong> So cant I omit parenthesis when having more than one parameters in method call? </p>
  
  <p><strong>Q.</strong> Also can we omit parenthesis when calling class constructor?</p>