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:
Diffstat (limited to 'mcs/tests/test-120.cs')
-rwxr-xr-xmcs/tests/test-120.cs56
1 files changed, 0 insertions, 56 deletions
diff --git a/mcs/tests/test-120.cs b/mcs/tests/test-120.cs
deleted file mode 100755
index 5d4f5180a34..00000000000
--- a/mcs/tests/test-120.cs
+++ /dev/null
@@ -1,56 +0,0 @@
-//
-// This tests checks that the compiler catches the special attributes
-// for in a struct for CharSet, and turns the right bit on the TypeAttribute
-//
-using System;
-using System.Reflection;
-using System.Runtime.InteropServices;
-
-[StructLayout(LayoutKind.Explicit, Size=32,CharSet=CharSet.Unicode)]
-struct MyUnicode
-{
- [FieldOffset(0)] public float fh_float;
- [FieldOffset(0)] public int fh_int;
-}
-
-[StructLayout(LayoutKind.Explicit, Size=32,CharSet=CharSet.Ansi)]
-struct MyAnsi
-{
- [FieldOffset(0)] public float fh_float;
- [FieldOffset(0)] public int fh_int;
-}
-[StructLayout(LayoutKind.Explicit, Size=32,CharSet=CharSet.Auto)]
-struct MyAuto
-{
- [FieldOffset(0)] public float fh_float;
- [FieldOffset(0)] public int fh_int;
-}
-
-class test
-{
-
- static int Main ()
- {
- Type t = typeof (MyUnicode);
-
- if ((t.Attributes & TypeAttributes.UnicodeClass) != TypeAttributes.UnicodeClass){
- Console.WriteLine ("Class MyUnicode does not have Unicode bit set");
- return 1;
- }
-
- t = typeof (MyAuto);
- if ((t.Attributes & TypeAttributes.AutoClass) != TypeAttributes.AutoClass){
- Console.WriteLine ("Class MyAuto does not have Auto bit set");
- return 2;
- }
-
- t = typeof (MyAnsi);
-
- if ((t.Attributes & TypeAttributes.AnsiClass) != TypeAttributes.AnsiClass){
- Console.WriteLine ("Class MyUnicode does not have Ansi bit set");
- return 3;
- }
-
- return 0;
- }
-}