Hello Daniel,

BCS wrote:

here's a general version that should work but dosn't:

The problem is that out and ref aren't types; they're storage classes,
and D's current metaprogramming system has no way of accessing these.

You CAN get at them with .stringof, but that's 100% undocumented and a
MASSIVE pain in the arse.  It also means you have to write horrible
parsing code every single time you want to wrap a function.

There *really* has to be a better way.


the really painful bit is that the tuple from is(T A == function) has the ref/out stuff in it as shown by the first static assert but it gets dropped when it's used as an argument list (as show my the second [identical!] assert).


Reply via email to