|
From: | Gopal.V <address@hidden> |
Subject: | [Dotgnu-pnet-commits] CVS: cscctest/csharp/expr ternary1.cs,NONE,1.1 ternary1.il,NONE,1.1 ternary1.jl,NONE,1.1 Makefile.am,1.24,1.25 |
Date: | Sun, 09 Mar 2003 03:47:52 -0500 |
Update of /cvsroot/dotgnu-pnet/cscctest/csharp/expr In directory subversions:/tmp/cvs-serv3642/csharp/expr Modified Files: Makefile.am Added Files: ternary1.cs ternary1.il ternary1.jl Log Message: Tests for ternary operators --- NEW FILE --- using System; enum Dino { None=0, Trex=1 }; class FooBar { static void Foo(bool x) { String s=(x ? Dino.Trex : 0).ToString(); s=(x ? 0 : Dino.Trex).ToString(); } } --- NEW FILE --- .assembly extern '.library' { .ver 0:0:0:0 } .assembly '<Assembly>' { .ver 0:0:0:0 } .module '<Module>' .class private auto sealed serializable ansi 'Dino' extends ['.library']'System'.'Enum' { .field public static literal valuetype 'Dino' 'None' = int32(0x00000000) .field public static literal valuetype 'Dino' 'Trex' = int32(0x00000001) .field public specialname rtspecialname int32 'value__' } // class Dino .class private auto ansi 'FooBar' extends ['.library']'System'.'Object' { .method private static hidebysig void 'Foo'(bool 'x') cil managed { .locals init (class ['.library']'System'.'String') ldarg.0 brfalse ?L1 ldc.i4.1 br ?L2 ?L1: ldc.i4.0 ?L2: box 'Dino' callvirt instance class ['.library']'System'.'String' ['.library']'System'.'Object'::'ToString'() stloc.0 ldarg.0 brfalse ?L3 ldc.i4.0 br ?L4 ?L3: ldc.i4.1 ?L4: box 'Dino' callvirt instance class ['.library']'System'.'String' ['.library']'System'.'Object'::'ToString'() stloc.0 ret .maxstack 1 } // method Foo .method public hidebysig specialname rtspecialname instance void '.ctor'() cil managed { ldarg.0 call instance void ['.library']'System'.'Object'::'.ctor'() ret .maxstack 1 } // method .ctor } // class FooBar --- NEW FILE --- .assembly extern '.library' { .ver 0:0:0:0 } .assembly '<Assembly>' { .ver 0:0:0:0 } .module '<Module>' .class private auto sealed serializable ansi 'Dino' extends ['.library']'System'.'Enum' { .field public static literal valuetype 'Dino' 'None' = int32(0x00000000) .field public static literal valuetype 'Dino' 'Trex' = int32(0x00000001) .field public specialname rtspecialname int32 'value__' } // class Dino .class private auto ansi 'FooBar' extends ['.library']'System'.'Object' { .method private static hidebysig void 'Foo'(bool 'x') cil managed java { iload_0 ifeq ?L1 iconst_1 goto ?L2 ?L1: iconst_0 ?L2: invokestatic "Dino" "copyIn__" "(I)LDino;" invokevirtual instance class ['.library']'System'.'String' ['.library']'System'.'Object'::'ToString'() astore_1 iload_0 ifeq ?L3 iconst_0 goto ?L4 ?L3: iconst_1 ?L4: invokestatic "Dino" "copyIn__" "(I)LDino;" invokevirtual instance class ['.library']'System'.'String' ['.library']'System'.'Object'::'ToString'() astore_1 return .locals 2 .maxstack 1 } // method Foo .method public hidebysig specialname rtspecialname instance void '.ctor'() cil managed java { aload_0 invokespecial instance void ['.library']'System'.'Object'::'.ctor'() return .locals 1 .maxstack 1 } // method .ctor } // class FooBar Index: Makefile.am =================================================================== RCS file: /cvsroot/dotgnu-pnet/cscctest/csharp/expr/Makefile.am,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -r1.24 -r1.25 *** Makefile.am 26 Feb 2003 11:43:28 -0000 1.24 --- Makefile.am 9 Mar 2003 08:47:49 -0000 1.25 *************** *** 51,54 **** --- 51,55 ---- sizeof1.cs \ sizeof2.cs \ + ternary1.cs \ this1.cs \ typedref1.cs \
[Prev in Thread] | Current Thread | [Next in Thread] |