示例#1
0
文件: Program.cs 项目: asugubkin/OOPP
        static void Operators()
        {
            Console.WriteLine("Operators");
            var o1 = new OpClass(10);
            var o2 = new OpClass(100);

            (o1 + o2).f();
            fo(++o1);
            o1.f();
            fo(o2++);
            o2.f();
            int    i = o1;
            int    j = (int)o2;
            double d = (double)o1;
            double f = o2;
        }
示例#2
0
文件: Program.cs 项目: asugubkin/OOPP
 static void fo(OpClass o)
 {
     o.f();
 }