dotgnu-pnet-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dotgnu-pnet-commits] CVS: cscctest/csharp/class nested2.cs,NONE,1.1 nes


From: Gopal.V <address@hidden>
Subject: [Dotgnu-pnet-commits] CVS: cscctest/csharp/class nested2.cs,NONE,1.1 nested2.il,NONE,1.1 nested2.jl,NONE,1.1
Date: Sun, 17 Nov 2002 05:12:07 -0500

Update of /cvsroot/dotgnu-pnet/cscctest/csharp/class
In directory subversions:/tmp/cvs-serv16822/csharp/class

Added Files:
        nested2.cs nested2.il nested2.jl 
Log Message:
additional tests and some changes in the output


--- NEW FILE ---
/*
 * nested2.cs - Test scoping in nested classes.
 *
 * Copyright (C) 2002  Southern Storm Software, Pty Ltd.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

class Test
{
        class Test2
        {
                public void Foo(int x)
                {
                        x=10;
                }
        }

        class Test3 : Test2
        {
                public void Foo(Test2 x)
                {
                        x.Foo(10);
                }
        }
}

namespace X
{

class Test
{
        public class Test2
        {
        }
}

class Test3 : Test.Test2
{
}

}

--- NEW FILE ---
.assembly extern '.library'
{
        .ver 0:0:0:0
}
.assembly '<Assembly>'
{
        .ver 0:0:0:0
}
.module '<Module>'
.class private auto ansi 'Test' extends ['.library']'System'.'Object'
{
.class nested private auto ansi 'Test2' extends ['.library']'System'.'Object'
{
.method public hidebysig instance void 'Foo'(int32 'x') cil managed 
{
        ldc.i4.s        10
        starg.s 1
        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 Test2
.class nested private auto ansi 'Test3' extends 'Test'/'Test2'
{
.method public hidebysig instance void 'Foo'(class 'Test'/'Test2' 'x') cil 
managed 
{
        ldarg.1
        ldc.i4.s        10
        callvirt        instance void 'Test'/'Test2'::'Foo'(int32)
        ret
        .maxstack 2
} // method Foo
.method public hidebysig specialname rtspecialname instance void '.ctor'() cil 
managed 
{
        ldarg.0
        call    instance void 'Test'/'Test2'::'.ctor'()
        ret
        .maxstack 1
} // method .ctor
} // class Test3
.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 Test
.namespace 'X'
{
.class private auto ansi 'Test' extends ['.library']'System'.'Object'
{
.class nested public auto ansi 'Test2' extends ['.library']'System'.'Object'
{
.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 Test2
.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 Test
} // namespace X
.namespace 'X'
{
.class private auto ansi 'Test3' extends 'X'.'Test'/'Test2'
{
.method public hidebysig specialname rtspecialname instance void '.ctor'() cil 
managed 
{
        ldarg.0
        call    instance void 'X'.'Test'/'Test2'::'.ctor'()
        ret
        .maxstack 1
} // method .ctor
} // class Test3
} // namespace X

--- NEW FILE ---
.assembly extern '.library'
{
        .ver 0:0:0:0
}
.assembly '<Assembly>'
{
        .ver 0:0:0:0
}
.module '<Module>'
.class private auto ansi 'Test' extends ['.library']'System'.'Object'
{
.class nested private auto ansi 'Test2' extends ['.library']'System'.'Object'
{
.method public hidebysig instance void 'Foo'(int32 'x') cil managed java 
{
        bipush  10
        istore_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 Test2
.class nested private auto ansi 'Test3' extends 'Test'/'Test2'
{
.method public hidebysig instance void 'Foo'(class 'Test'/'Test2' 'x') cil 
managed java 
{
        aload_1
        bipush  10
        invokespecial   instance void 'Test'/'Test2'::'Foo'(int32)
        return
        .locals 2
        .maxstack 2
} // method Foo
.method public hidebysig specialname rtspecialname instance void '.ctor'() cil 
managed java 
{
        aload_0
        invokespecial   instance void 'Test'/'Test2'::'.ctor'()
        return
        .locals 1
        .maxstack 1
} // method .ctor
} // class Test3
.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 Test
.namespace 'X'
{
.class private auto ansi 'Test' extends ['.library']'System'.'Object'
{
.class nested public auto ansi 'Test2' extends ['.library']'System'.'Object'
{
.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 Test2
.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 Test
} // namespace X
.namespace 'X'
{
.class private auto ansi 'Test3' extends 'X'.'Test'/'Test2'
{
.method public hidebysig specialname rtspecialname instance void '.ctor'() cil 
managed java 
{
        aload_0
        invokespecial   instance void 'X'.'Test'/'Test2'::'.ctor'()
        return
        .locals 1
        .maxstack 1
} // method .ctor
} // class Test3
} // namespace X





reply via email to

[Prev in Thread] Current Thread [Next in Thread]