コード例 #1
0
        // returns 999
        static int Main(string[] args)
        {
            foo f = new foo();

            f.SetCount(1000);
            return(f.GetCount());
        }
コード例 #2
0
        // returns 1234
        static int Main(string[] args)
        {
            foo f = new foo();

            f.z = 1234;
            return(f.z);
        }
コード例 #3
0
        // returns 684870
        static int Main(string[] args)
        {
            foo f = new foo();

            f.z = 1234;
            foo f2 = new foo();

            f2.z = 555;
            return(f.z * f2.z);
        }
コード例 #4
0
ファイル: class5.cs プロジェクト: martydill/PyCIL
        // returns 9999
        static int Main(string[] args)
        {
            bar b = new bar();
             foo f = new foo();
             b.f = f;

             if(b.f == f)
            return 9999;
             else
            return -1;
        }
コード例 #5
0
ファイル: class3.cs プロジェクト: martydill/PyCIL
        // returns 45
        static int Main(string[] args)
        {
            int counter = 0;
             for (int i = 0; i < 10; ++i)
             {
            foo f = new foo();
            f.z = i;
            counter += f.z;
             }

             return counter;
        }
コード例 #6
0
        // returns 45
        static int Main(string[] args)
        {
            int counter = 0;

            for (int i = 0; i < 10; ++i)
            {
                foo f = new foo();
                f.z      = i;
                counter += f.z;
            }

            return(counter);
        }
コード例 #7
0
ファイル: class5.cs プロジェクト: memsom/PyCIL
        // returns 9999
        static int Main(string[] args)
        {
            bar b = new bar();
            foo f = new foo();

            b.f = f;

            if (b.f == f)
            {
                return(9999);
            }
            else
            {
                return(-1);
            }
        }
コード例 #8
0
ファイル: class.cs プロジェクト: martydill/PyCIL
 // returns 1234
 static int Main(string[] args)
 {
     foo f = new foo();
     f.z = 1234;
     return f.z;
 }
コード例 #9
0
ファイル: class7.cs プロジェクト: martydill/PyCIL
 // returns 999
 static int Main(string[] args)
 {
     foo f = new foo();
     f.SetCount(1000);
     return f.GetCount();
 }
コード例 #10
0
 public bar()
 {
     m_foo       = new foo();
     m_foo.value = 42;
 }