From 42216c3b9e6068cca33802b80b81d559853e4432 Mon Sep 17 00:00:00 2001 From: Alecio Furanze Date: Tue, 21 May 2024 22:20:04 +0200 Subject: [PATCH] Delete StructDebug.cs --- test/primitive/StructDebug.cs | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100644 test/primitive/StructDebug.cs diff --git a/test/primitive/StructDebug.cs b/test/primitive/StructDebug.cs deleted file mode 100644 index b9cd826..0000000 --- a/test/primitive/StructDebug.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; - -namespace ByterTest.primitive; - -public class StructDebug -{ - struct Z - { - public int X { get; set; } - } - - void _() - { - Z z1 = new Z(); - z1.GetType().GetProperty("X").SetValue(z1, 100, null); - - Console.WriteLine(z1.X); //z1.X dont changed - - object z2 = new Z(); - z2.GetType().GetProperty("X").SetValue(z2, 100, null); - - - Console.WriteLine(((Z)z2).X); //z2.x changed to 100 - - Z z3 = new Z(); - object _z3 = z3; - _z3.GetType().GetProperty("X").SetValue(_z3, 100, null); - z3 = (Z)_z3; - Console.WriteLine(z3.X); //z3.x changed to 100 - } -} \ No newline at end of file