diff options
Diffstat (limited to 'test/Mono.Linker.Tests.Cases/LinkXml/PreserveBackingFieldWhenPropertyIsKept.cs')
-rw-r--r-- | test/Mono.Linker.Tests.Cases/LinkXml/PreserveBackingFieldWhenPropertyIsKept.cs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/test/Mono.Linker.Tests.Cases/LinkXml/PreserveBackingFieldWhenPropertyIsKept.cs b/test/Mono.Linker.Tests.Cases/LinkXml/PreserveBackingFieldWhenPropertyIsKept.cs new file mode 100644 index 000000000..c319c1442 --- /dev/null +++ b/test/Mono.Linker.Tests.Cases/LinkXml/PreserveBackingFieldWhenPropertyIsKept.cs @@ -0,0 +1,18 @@ +using Mono.Linker.Tests.Cases.Expectations.Assertions; + +namespace Mono.Linker.Tests.Cases.LinkXml +{ + abstract class PreserveBackingFieldWhenPropertyIsKept + { + public static void Main () + { + Prop = 1; + } + + public abstract int Base { set; } + + [Kept] + [KeptBackingField] + public static int Prop { get; [Kept] set; } + } +}
\ No newline at end of file |