title: Casting system.array to object in c#
body: <p>my function has the following signature</p>
  
  <pre class="lang-cs prettyprint-override"><code>function myfunction(ref object)
  </code></pre>
  
  <p>I use it as such </p>
  
  <pre class="lang-cs prettyprint-override"><code> Array arr = Array.CreateInstance(System.Type.GetType("System.String"), 2);
    arr.SetValue("1", 0);
  
    myfunction( ref arr);
  </code></pre>
  
  <p>And I am getting</p>
  
  <blockquote>
    <p>"cannot convert from 'ref System.Array' to 'ref object'"</p>
  </blockquote>
  
  <p>I was under the impression that System.Array is object ...so why am I getting this error? Is object different from Object?</p>