www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - A way to detect a ref parameter

Is there any way to detect if the nth parameter of a delegate type or function
pointer type is ref, or out?
(short of scanning the mangleof, of course)
If not, I vote the language be changed in 2.0 to allow this.
It's very annoying to be completely unable to wrap delegates that contain ref,
while maintaining their functionality.
One way I could see is to turn ref into a storage type, and add a way to detect
it via templates.

Dec 08 2007