Ignore AssociatedSourceType on UnmanagedCallersOnly in CoreCLR#130270
Ignore AssociatedSourceType on UnmanagedCallersOnly in CoreCLR#130270MichalStrehovsky with Copilot wants to merge 10 commits into
Conversation
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
|
Tagging subscribers to this area: @agocke |
|
@copilot same problem with mono: * Assertion at /__w/1/s/src/mono/mono/metadata/marshal.c:3478, condition `is_ok (error)' not met, function:mono_marshal_set_callconv_from_unmanaged_callers_only_attribute, Binary format of the specified custom attribute was invalid. assembly: type:UnmanagedCallersOnlyBasicTest member:(null) |
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Addressed for Mono in baec198. The Mono path now parses the UnmanagedCallersOnly custom attribute blob directly for |
|
@copilot this is a lot of new code in Mono. we only need this to support this narrow path with the existing limitations (e.g. multiple callconvs do not work). can you address the specific issue with the extra property only? I don't want 250 lines of new code for something that was handled by 12 lines. keep the diff against |
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
Co-authored-by: MichalStrehovsky <13110571+MichalStrehovsky@users.noreply.github.com>
CoreCLR rejected
[UnmanagedCallersOnly]attributes containing the newerAssociatedSourceTypenamed argument, throwingMETA_E_CA_UNKNOWN_ARGUMENTwhen setting up unmanaged callbacks. Assemblies valid for NativeAOT could therefore fail under CoreCLR.Runtime
AssociatedSourceTypein CoreCLR’s hand-writtenUnmanagedCallersOnlyAttributeparser.Regression coverage