[llvm-dev] libclang API to access static array initializer (original) (raw)

Andrew Kelley via llvm-dev llvm-dev at lists.llvm.org
Wed Nov 29 20:20:37 PST 2017


In this C code:

static const int array[2] = {1, 2};

Parsed with libclang, we get a VarDecl. evaluateValue() returns NULL. However the initialization value should be known. How can I access the array information using the libclang API?

Regards, Andrew -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20171129/b8560907/attachment.html>



More information about the llvm-dev mailing list