Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/linker.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Boemer <sbomer@gmail.com>2019-02-20 01:16:58 +0300
committerMarek Safar <marek.safar@gmail.com>2019-02-20 01:16:58 +0300
commitfa9ccbdaf6907c69ef1bb117906f8f012218d57f (patch)
tree4d4cbe2d4079a35edca350a4e444831c2f9dd19a /test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs
parente64148792193bf7d706428a64632ebf7f8023d3b (diff)
Adopt new directory layout (#466)
This organizes the source and test projects as follows: - source projects go in `src/project/projectfile.csproj` - test projects go in `test/project/projectfile.csproj` The uniform layout of projects is part of the arcade onboarding (see https://github.com/mono/linker/issues/452).
Diffstat (limited to 'test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs')
-rw-r--r--test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs34
1 files changed, 34 insertions, 0 deletions
diff --git a/test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs b/test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs
new file mode 100644
index 000000000..16851b0cf
--- /dev/null
+++ b/test/Mono.Linker.Tests.Cases/Reflection/ConstructorUsedViaReflection.cs
@@ -0,0 +1,34 @@
+using System;
+using System.Reflection;
+using Mono.Linker.Tests.Cases.Expectations.Assertions;
+
+namespace Mono.Linker.Tests.Cases.Reflection
+{
+ public class ConstructorUsedViaReflection {
+ public static void Main ()
+ {
+ var constructor = typeof (OnlyUsedViaReflection).GetConstructor (BindingFlags.Public, null, new Type[]{}, new ParameterModifier[]{});
+ constructor.Invoke (null, new object[] { });
+ }
+
+ [Kept]
+ private class OnlyUsedViaReflection {
+ [Kept]
+ public OnlyUsedViaReflection ()
+ { }
+
+ [Kept]
+ public OnlyUsedViaReflection(string bar)
+ { }
+
+ private OnlyUsedViaReflection (int foo)
+ { }
+
+ protected OnlyUsedViaReflection(int foo, int bar)
+ { }
+
+ internal OnlyUsedViaReflection(int foo, int bar, int baz)
+ { }
+ }
+ }
+}