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
For as far as i have used this, AssemblyGenerator.GenerateAssemblyBytes() seems to work for most assemblies present in application memory, but unfortunately not for 'System.Private.CoreLib'.
It specifically throws;
System.ArgumentException: 'Type cannot be found: "System.Runtime.CompilerServices.RefSafetyRulesAttribute, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Arg_ParamName_Name'
in GetTypeHandle() of AssemblyMetadata.cs
I suppose this is a bug?
The text was updated successfully, but these errors were encountered:
Just realized that GetTypeHandle() is a microsoft function
Looking at the IL from my debugger i think the exception actually mapped to line 35 in CreateCustomAttributes() of AssemblyGenerator.Attributes.cs
Heptagram64
changed the title
AssemblyGenerator fails when generating bytes for 'System.Private.CoreLib'
AssemblyGenerator fails when generating bytes for 'System.Private.CoreLib' in .NET 8
Jun 25, 2024
Heptagram64
changed the title
AssemblyGenerator fails when generating bytes for 'System.Private.CoreLib' in .NET 8
AssemblyGenerator fails when generating bytes for 'System.Private.CoreLib' in .NET 8.0
Jun 25, 2024
For as far as i have used this, AssemblyGenerator.GenerateAssemblyBytes() seems to work for most assemblies present in application memory, but unfortunately not for 'System.Private.CoreLib'.
It specifically throws;
System.ArgumentException: 'Type cannot be found: "System.Runtime.CompilerServices.RefSafetyRulesAttribute, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Arg_ParamName_Name'
in GetTypeHandle() of AssemblyMetadata.cs
I suppose this is a bug?
The text was updated successfully, but these errors were encountered: