You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mono.Linker.LinkerFatalErrorException: ILLink: error IL1005: Mono.Linker.Tests.Cases.Attributes.GenericEnumInAttribute.Main(): Error processing method 'Mono.Linker.Tests.Cases.Attributes.GenericEnumInAttribute.Method()' in assembly 'test.exe'
---> System.NotImplementedException: GenericInst
at Mono.Cecil.SignatureReader.ReadPrimitiveValue(ElementType type) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3643
at Mono.Cecil.SignatureReader.ReadCustomAttributeElementValue(TypeReference type) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3611
at Mono.Cecil.SignatureReader.ReadCustomAttributeElement(TypeReference type) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3591
at Mono.Cecil.SignatureReader.ReadCustomAttributeElement(TypeReference type) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3591
at Mono.Cecil.SignatureReader.ReadCustomAttributeFixedArgument(TypeReference type) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3526
at Mono.Cecil.SignatureReader.ReadCustomAttributeNamedArgument(Collection`1& fields, Collection`1& properties) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3556
at Mono.Cecil.SignatureReader.ReadCustomAttributeNamedArguments(UInt16 count, Collection`1& fields, Collection`1& properties) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 3534
at Mono.Cecil.MetadataReader.ReadCustomAttributeSignature(CustomAttribute attribute) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\AssemblyReader.cs:line 2597
at Mono.Cecil.CustomAttribute.<Resolve>b__35_0(CustomAttribute attribute, MetadataReader reader) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\CustomAttribute.cs:line 204
at Mono.Cecil.ModuleDefinition.Read[TItem](TItem item, Action`2 read) in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\ModuleDefinition.cs:line 982
at Mono.Cecil.CustomAttribute.Resolve() in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\CustomAttribute.cs:line 202
at Mono.Cecil.CustomAttribute.get_HasConstructorArguments() in C:\Unity\dev\unity-monolinker-2\external\cecil\Mono.Cecil\CustomAttribute.cs:line 99
at Mono.Linker.Steps.MarkStep.MarkCustomAttributeArguments(CustomAttribute ca) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 1284
at Mono.Linker.Steps.MarkStep.MarkCustomAttribute(CustomAttribute ca, DependencyInfo& reason) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 1079
at Mono.Linker.Steps.MarkStep.MarkCustomAttributes(ICustomAttributeProvider provider, DependencyInfo& reason) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 793
at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method, DependencyInfo& reason, Scope& scope) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 2975
at Mono.Linker.Steps.MarkStep.ProcessQueue() in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 513
--- End of inner exception stack trace ---
at Mono.Linker.Steps.MarkStep.ProcessQueue() in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 515
at Mono.Linker.Steps.MarkStep.ProcessPrimaryQueue() in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 434
at Mono.Linker.Steps.MarkStep.Process() in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 375
at Mono.Linker.Steps.MarkStep.Process(LinkContext context) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker.Steps\MarkStep.cs:line 213
at Mono.Linker.Pipeline.ProcessStep(LinkContext context, IStep step) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker\Pipeline.cs:line 166
at Mono.Linker.Pipeline.Process(LinkContext context) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker\Pipeline.cs:line 159
at Mono.Linker.Driver.Run(ILogger customLogger, Boolean throwOnFatalLinkerException) in C:\Unity\dev\unity-monolinker-2\src\linker\Linker\Driver.cs:line 771
Here is a test case to reproduce
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using Mono.Linker.Tests.Cases.Expectations.Assertions;
namespace Mono.Linker.Tests.Cases.Attributes
{
public class GenericEnumInAttribute
{
public static void Main ()
{
Method();
}
[Bar (Value = MyGenericClass<string>.MyEnum.One)]
[KeptAttributeAttribute (typeof (BarAttribute))]
static void Method ()
{
}
[Kept]
[KeptBaseType (typeof(Attribute))]
class BarAttribute : Attribute
{
[Kept]
public object Value { get; [Kept] set; }
}
[Kept]
[KeptMember ("value__")]
[KeptBaseType (typeof (Enum))]
class MyGenericClass<T>
{
[Kept]
public enum MyEnum
{
[Kept]
One,
}
}
}
}
The text was updated successfully, but these errors were encountered:
Here is a test case to reproduce
The text was updated successfully, but these errors were encountered: