Skip to content

Conversation

@buyaa-n
Copy link
Contributor

@buyaa-n buyaa-n commented Dec 7, 2023

  • Added implementation for DefineMethodOverrideCore(...), GetInterfaceMap(...), GetMethods(...), GetMethodImpl(...), IsAssignableFrom(...) overrides and a few other related APIs
    • Mainly followed scenarios from runtime implementation, added corresponding tests (a few IL level things not testable)
    • In runtime implementation validations related to DefineMethodOverrideCore(...) was happening during type creation, moved the validations to the corresponding API call and throwing ArgumentException instead of TypeLoadException
  • Added validations on CreateType() for not implemented methods, methods not having IL when supposed to or having IL when not supposed to have etc.
  • Always set MethodAttributes.RTSpecialName for constructors (in addition to MethodAttributes.SpecialName)
  • Imported AssemblyBuilderB.Save test from mono and fixed bugs found
    • Corrected logic for getting SignatureCallingConvention of a method
    • Fixed bug found with MarshalAsAttribute attribute with UnmanagedType.CustomMarshaler field type
    • Bug found with writing nested type

Contributes to #92975

@ghost
Copy link

ghost commented Dec 7, 2023

Tagging subscribers to this area: @dotnet/area-system-reflection-emit
See info in area-owners.md if you want to be subscribed.

Issue Details
  • Added implementation for DefineMethodOverrideCore(...), GetInterfaceMap(), IsAssignableFrom(...) overrides and a few other related APIs
    • Mainly followed scenarios from runtime implementation
    • In runtime implementation validations related to DefineMethodOverrideCore(...) was happening during type creation, moved the validations to the corresponding API call and throwing ArgumentException instead of TypeLoadException
  • Imported AB.Save test from mono and fixed bugs found
Author: buyaa-n
Assignees: -
Labels:

area-System.Reflection.Emit

Milestone: -

@buyaa-n buyaa-n closed this Dec 22, 2023
@buyaa-n buyaa-n reopened this Dec 22, 2023
@buyaa-n
Copy link
Contributor Author

buyaa-n commented Dec 22, 2023

Build failure unrelated and reported

@buyaa-n buyaa-n merged commit 9b01699 into dotnet:main Dec 22, 2023
@buyaa-n buyaa-n deleted the implement_apis branch December 22, 2023 18:31
@github-actions github-actions bot locked and limited conversation to collaborators Jan 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants