Skip to content
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

Use implicit/explicit cast operator if present #7

Open
ygoe opened this issue Jun 7, 2020 · 0 comments
Open

Use implicit/explicit cast operator if present #7

ygoe opened this issue Jun 7, 2020 · 0 comments

Comments

@ygoe
Copy link
Owner

ygoe commented Jun 7, 2020

If the converter is running out of options, it could look for a public static op_Implicit or op_Explicit method on the source type that returns the destination type and accepts a single parameter of the source type, then call it.

See also: https://stackoverflow.com/a/32025393

The reflection result should be cached, and it should be possible to clear the cache on demand to free memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant