New test.
authorMarek Safar <marek.safar@gmail.com>
Fri, 13 Feb 2009 12:09:24 +0000 (12:09 -0000)
committerMarek Safar <marek.safar@gmail.com>
Fri, 13 Feb 2009 12:09:24 +0000 (12:09 -0000)
svn path=/trunk/mcs/; revision=126827

mcs/tests/gtest-anon-24.cs
mcs/tests/ver-il-gmcs.xml

index 4bc12f7747cf00a7319c839b299017f055efc81c..ad01bcbdc2b7ae0dc35980fd2c74bf28ebe3c77e 100644 (file)
@@ -1,6 +1,8 @@
 using System;
 using System.Collections.Generic;
 
+// Generics mutate tests
+
 class Disposable<T> : IDisposable
 {
        public void Dispose ()
@@ -113,6 +115,17 @@ class Test
                };
        }
        
+       public void ArrayMutate<T> (T[] array)
+       {
+               int r = 4;
+               Action<int> anonMeth = delegate (int slc) {
+                       long[] idx = new long[] { 0, 0 };
+                       for (int i = 0; i < r; i++) {
+                               idx [0] = i;
+                       }
+               };
+       }
+       
        public static int Main ()
        {
                if (For (new List<int> { 5, 10 })() [1] != 10)
@@ -157,4 +170,4 @@ class Test
                Console.WriteLine ("OK");
                return 0;
        }
-}
\ No newline at end of file
+}
index c360195115a171e0fdfb3f144649cef6ac63fc31..1b647d3bb714860c7d2cd979a42511274343f0d5 100644 (file)
         <size>56</size>
       </method>
     </type>
+    <type name="Test">
+      <method name="Void ArrayMutate[T](T[])">
+        <size>27</size>
+      </method>
+    </type>
+    <type name="Test+&lt;ArrayMutate&gt;c__AnonStorey9`1[T]">
+      <method name="Void .ctor()">
+        <size>7</size>
+      </method>
+      <method name="Void &lt;&gt;m__9(Int32)">
+        <size>36</size>
+      </method>
+    </type>
   </test>
   <test name="gtest-anon-25.cs">
     <type name="HS`1[T]">