diff options
Diffstat (limited to 'test/Mono.Linker.Tests.Cases/Statics/UnusedStaticFieldInitializer.cs')
-rw-r--r-- | test/Mono.Linker.Tests.Cases/Statics/UnusedStaticFieldInitializer.cs | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/Mono.Linker.Tests.Cases/Statics/UnusedStaticFieldInitializer.cs b/test/Mono.Linker.Tests.Cases/Statics/UnusedStaticFieldInitializer.cs new file mode 100644 index 000000000..5f0b96f77 --- /dev/null +++ b/test/Mono.Linker.Tests.Cases/Statics/UnusedStaticFieldInitializer.cs @@ -0,0 +1,22 @@ +using Mono.Linker.Tests.Cases.Expectations.Assertions; + +namespace Mono.Linker.Tests.Cases.Statics +{ + public class UnusedStaticFieldInitializer + { + public static void Main () + { + C.Foo (); + } + + static class C + { + public static object o = new object (); + + [Kept] + public static void Foo () + { + } + } + } +} |