-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support ldftn #42488
Merged
8 commits merged into
dotnet:features/function-pointers
from
333fred:method-conversions
Mar 28, 2020
Merged
Support ldftn #42488
8 commits merged into
dotnet:features/function-pointers
from
333fred:method-conversions
Mar 28, 2020
Commits on Mar 27, 2020
-
This change enables an address-of operator (&) to target a method group, and for that result to be converted a function pointer type. Much like a method-group-to-delegate conversion, an address-of-method-group has no natural type, and must be target-typed to something with a compatible function pointer type signature. Compatible is defined in our function pointer spec here: https://github.com/dotnet/csharplang/blob/master/proposals/function-pointers.md#function-pointer-conversions An address of a method group, if valid, will load the function with the ldftm CIL instruction, and this token can then be `calli`'d. This PR does not implement support for `NativeCallableAttribute`, that will come in a future PR. When that does, it will change the calling convention that the method can be converted to.
Configuration menu - View commit details
-
Copy full SHA for 2908863 - Browse repository at this point
Copy the full SHA 2908863View commit details -
Some spelling changes as requested. Fixed a bug by specifying the parameter name to PerformOverloadResolution Updated baselines Added a test for `void*`
Configuration menu - View commit details
-
Copy full SHA for 4cc0ba0 - Browse repository at this point
Copy the full SHA 4cc0ba0View commit details -
Handle additional conversion cases. Clean up error reporting. Add more tests. Handle a couple of bad-code crashes.
Configuration menu - View commit details
-
Copy full SHA for 77b08e3 - Browse repository at this point
Copy the full SHA 77b08e3View commit details -
Configuration menu - View commit details
-
Copy full SHA for a3ac488 - Browse repository at this point
Copy the full SHA a3ac488View commit details -
Additional calling convention validation. Test adjustments.
Configuration menu - View commit details
-
Copy full SHA for d8440d9 - Browse repository at this point
Copy the full SHA d8440d9View commit details -
Adjust some error messages and reporting for clarity. Add new test for invalid metadata.
Configuration menu - View commit details
-
Copy full SHA for c196e3b - Browse repository at this point
Copy the full SHA c196e3bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 28bc3db - Browse repository at this point
Copy the full SHA 28bc3dbView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0946f8c - Browse repository at this point
Copy the full SHA 0946f8cView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.