diff options
author | Marek Safar <marek.safar@gmail.com> | 2020-04-19 11:16:34 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2020-04-20 14:45:03 +0300 |
commit | 8fc1d252ee5727da6642f59113cd0451b5d82478 (patch) | |
tree | 3bb39acccb52e80717fc34163717698d187b13f0 /test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs | |
parent | 93663d3c03256def21703e3b368557852d891934 (diff) |
Handle correctly individual methods on non required types in linker
descriptor
Add better code coverage for this configuration
Fixes #1107
Diffstat (limited to 'test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs')
-rw-r--r-- | test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs b/test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs new file mode 100644 index 000000000..b795e8f24 --- /dev/null +++ b/test/Mono.Linker.Tests.Cases/LinkXml/PreserveSecondLevelMethodsOfNonRequiredType.cs @@ -0,0 +1,35 @@ +using System.Collections.Generic; +using Mono.Linker.Tests.Cases.Expectations.Assertions; + +namespace Mono.Linker.Tests.Cases.LinkXml { + class PreserveSecondLevelMethodsOfNonRequiredType { + public static void Main () + { + new Unused (); + } + + [Kept] + class Unused + { + [Kept] + public Unused () + { + } + + [Kept] + private void PreservedMethod () + { + new SecondLevel (2); + } + } + + [Kept] + class SecondLevel + { + [Kept] + public SecondLevel (int arg) + { + } + } + } +}
\ No newline at end of file |