Why ParameterInfo::GetXXXCustomModifiers does not returns IsLong if the parameter is ByRef?

Posted by AZ on Stack Overflow See other posts from Stack Overflow or by AZ
Published on 2010-03-11T18:53:15Z Indexed on 2010/03/11 20:54 UTC
Read the original article Hit count: 220

Filed under:
|

Given a ParameterInfo p from this:

void foo(int modopt(IsLong) n);

p.GetOptionalCustomModifiers() returns a System.Runtime.CompilerServices.IsLong; however, if the method signature happens to be:

void foo(out int modopt(IsLong) n);

It does not. Is there a work around for this?

© Stack Overflow or respective owner

Related posts about .NET

Related posts about reflection