[cfe-commits] [PATCH] Utilize the indents in -ast-dump to draw structural information
Richard Trieu
rtrieu at google.com
Mon Jan 14 11:24:26 PST 2013
On Thu, Jan 10, 2013 at 10:34 PM, Philip Craig <philipjcraig at gmail.com>wrote:
>
> Are the parentheses still useful after doing this? They might be useful
> in some editors for quick navigation, but otherwise I think they make it a
> bit cluttered.
>
> http://llvm-reviews.chandlerc.com/D281
>
So you would prefer it like this?
TranslationUnitDecl 0x4bd5660 <<invalid sloc>>
|-TypedefDecl 0x4bd5ba0 <<invalid sloc>> __int128_t '__int128'
|-TypedefDecl 0x4bd5c00 <<invalid sloc>> __uint128_t 'unsigned __int128'
|-TypedefDecl 0x4bd5fc0 <<invalid sloc>> __builtin_va_list '__va_list_tag
[1]'
`-FunctionDecl 0x4bd61c0 <simple2.cc:1:1, line:5:1> main 'int (int, char
**)'
|-ParmVarDecl 0x4bd6020 <line:1:10, col:14> argc 'int'
|-ParmVarDecl 0x4bd60f0 <col:20, col:27> argv 'char **'
`-CompoundStmt 0x4c028c0 <col:33, line:5:1>
|-DeclStmt 0x4bd62f8 <line:2:3, col:12>
| `-VarDecl 0x4bd6280 <col:3, col:11> x 'int'
| `-IntegerLiteral 0x4bd62d8 <col:11> 'int' 5
|-DeclStmt 0x4c027c0 <line:3:3, col:12>
| `-VarDecl 0x4bd6320 <col:3, col:11> y 'int'
| `-IntegerLiteral 0x4c027a0 <col:11> 'int' 2
`-ReturnStmt 0x4c028a0 <line:4:3, col:16>
`-ParenExpr 0x4c02880 <col:10, col:16> 'int'
`-BinaryOperator 0x4c02858 <col:11, col:15> 'int' '*'
|-ImplicitCastExpr 0x4c02828 <col:11> 'int' <LValueToRValue>
| `-DeclRefExpr 0x4c027d8 <col:11> 'int' lvalue Var 0x4bd6280 'x'
'int'
`-ImplicitCastExpr 0x4c02840 <col:15> 'int' <LValueToRValue>
`-DeclRefExpr 0x4c02800 <col:15> 'int' lvalue Var 0x4bd6320 'y'
'int'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130114/11036a8a/attachment.html>
More information about the cfe-commits
mailing list