We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Is it possible we can get a way to generate [n] number of generic delegates on our side?
For example a game engine might want to wrap 3rd party libraries and hand writing [n] number of signatures to simply wrap something is really awful.
This is kinda why C# needs variadic generics, and typedef but sadly it does not.
The text was updated successfully, but these errors were encountered:
What exactly do you mean? Could you give samples? ^^
Sorry, something went wrong.
like generating things like...
public delegate Query<T1> QueryDelegate<T1>(); public delegate Query<T1, T2> QueryDelegate<T1, T2>(); ... n more times inside our own namespace.
In C++ if we wanted to forward things into our own engine namespaces we would just typedef it and statically link the library.
C# has no such feature so in order for me to write a wrapper or forward this api into my own namespace I would need to write a lot of boiler plate.
like generating things like... public delegate Query<T1> QueryDelegate<T1>(); public delegate Query<T1, T2> QueryDelegate<T1, T2>(); ... n more times inside our own namespace. In C++ if we wanted to forward things into our own engine namespaces we would just typedef it and statically link the library. C# has no such feature so in order for me to write a wrapper or forward this api into my own namespace I would need to write a lot of boiler plate.
Unfortunately that is not possible yet... you can however write your own source-generator to generate them ^^
No branches or pull requests
Is it possible we can get a way to generate [n] number of generic delegates on our side?
For example a game engine might want to wrap 3rd party libraries and hand writing [n] number of signatures to simply wrap something is really awful.
This is kinda why C# needs variadic generics, and typedef but sadly it does not.
The text was updated successfully, but these errors were encountered: