예제 #1
0
        public static int CastStructToInterfaceAndWriteInBoxed(Coord2 arg)
        {
            INormalize tmp = arg;
            var        y   = (int)tmp.Norm();

            return(arg.X + y); // arg.X should not change
        }
예제 #2
0
        public static int WriteInStructUsingNorm(Coord2 arg)
        {
            var y = (int)arg.Norm();

            return(arg.X + y); // arg.X should change
        }