[cfe-dev] Type of Array ParmVarDecl becomes PointerType

Peter clang_llvm_123-4 at yahoo.de
Thu Dec 22 01:57:13 PST 2011


Hi everybody,

I am using Version 3.0 and I am trying to parse the parameter of the following function declaration. 


void test(int myParam[])
{


}

I have written an ASTVisitor to iterate over the "ParamDecl's"of  my "FunctionDecl's"
The type of the "ParmVarDecl" myParam is always a "PointerType", although I am expecting
an "ArrayType". Is this normal behavior?
Also when I parse the following code I am loosing the size information. Sure, the
99 doesn't make much sense, but I need it for internal analysis ;)


void test(int myParam[99])
{


}

I hope someone can help!
Thanks in advance!!!!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20111222/e8e93eea/attachment.html>


More information about the cfe-dev mailing list