title: Scala: type mismatch when invoking fun with Int
body: <p>In my limited experience with Scala, there is a error in my code:</p>
  
  <pre><code>class TagCalculation {
      def test_string(arg1: String,arg2: String) = arg1 + " " + arg2
      def test_int(arg1: Int,arg2: Int) = arg1 + arg2
    }
  val get_test = new TagCalculation
  //test int, by the way it's Ok for String
  val test_int_para = Array(1,2)
  val argtypes2 = test_int_para.map(_.getClass)
  val method2 = get_test.getClass.getMethod("test_int", argtypes2: _*)
  method2.invoke(get_test,test_int_para: _*)
  </code></pre>
  
  <p>Outputs:</p>
  
  <blockquote>
    <p>console>:29: error: type mismatch;<br>  found   : Array[Int] <br> required:
    Array[_ &lt;: Object] <br>
                    method2.invoke(get_test,test_int_para: _*)</p>
  </blockquote>
  
  <p>Why did this error happened?</p>