Open Endilll opened 1 year ago
@llvm/issue-subscribers-clang-frontend
I believe the null pointers are by design, but I don't think that design is a particularly good one. For example, having NULL pointer child nodes in the AST makes it harder to write a correct recursive AST visitor because you have to watch out for instances where NULL occurs with special meaning. I think it would be better to use a concrete AST node instead of an in-band indicator.
Hi @Endilll, @AaronBallman Can anyone of you assign this task to me so that I could work
@shahidiqbal13 Sure! But assignment is not formal or binding in any way: everyone can work on anything they want in LLVM project.
Consider the following snippet with different usages of ellipsis:
clang -Xclang -ast-dump
outputs the following (omitting built-in typedefs):The first ellipsis (catch-all) is represented by
<<<NULL>>>
which comes from https://github.com/llvm/llvm-project/blob/b48ebad561dbbaddd989de3e9509253247dbf4b2/clang/lib/AST/TextNodeDumper.cpp#L245The second ellipsis (vararg) is not represented at all. Are those representations (or lack of thereof) by design? Is this inconsistency intentional? https://godbolt.org/z/EafKE5KWs