Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRavi Pratap M <ravi@mono-cvs.ximian.com>2001-11-28 20:12:19 +0300
committerRavi Pratap M <ravi@mono-cvs.ximian.com>2001-11-28 20:12:19 +0300
commitdb7248bb549cec35c5311e12a2df258e3df4baed (patch)
tree88f282a1ad2fe1c09bb0f83662ab621559132319 /mcs/tests/test-48.cs
parentb6e1585a30723061bd3066b85aaca8c15c227ef8 (diff)
2001-11-28 Ravi Pratap <ravi@ximian.com>
* test-48.cs : Add for constant emission tests. * makefile : Update for the above as it passes nicely :-) svn path=/trunk/mcs/; revision=1457
Diffstat (limited to 'mcs/tests/test-48.cs')
-rw-r--r--mcs/tests/test-48.cs31
1 files changed, 31 insertions, 0 deletions
diff --git a/mcs/tests/test-48.cs b/mcs/tests/test-48.cs
new file mode 100644
index 00000000000..5f92daf1253
--- /dev/null
+++ b/mcs/tests/test-48.cs
@@ -0,0 +1,31 @@
+using System;
+
+public class Blah {
+
+ public const int i = 5;
+
+ public static int Main ()
+ {
+ const int foo = 10;
+
+ Blah blah = new Blah ();
+ int j = Blah.i;
+
+ if (j != 5)
+ return 1;
+
+ if (foo != 10)
+ return 1;
+
+ for (int i = 0; i < 5; ++i){
+ const int bar = 15;
+
+ Console.WriteLine (bar);
+ Console.WriteLine (foo);
+ }
+
+ Console.WriteLine ("Constant emission test okay");
+
+ return 0;
+ }
+}