On Friday, 6 March 2020 at 15:05:56 UTC, wjoe wrote:
But didn't like the string part and that's when I introduced the alias fn because I figured maybe it's possible to do something like:
  factory.dispatch!(Bitmap.load)(handle, path);
and get the Bitmap part from that alias and hence save the duplicate Bitmap type in factory.dispatch!(Bitmap, Bitmap.load)(...);

ooh you can do that. on the alias, use __traits(identifier) to get thef ucntion name and __traits(parent) to get the class name! then it reduces to what we already wrote.

Reply via email to