[cfe-commits] r41602 - in /cfe/trunk: AST/StmtDumper.cpp clang.xcodeproj/project.pbxproj include/clang/AST/Stmt.h
Steve Naroff
snaroff at apple.com
Thu Aug 30 06:15:53 PDT 2007
On Aug 29, 2007, at 11:17 PM, Chris Lattner wrote:
> Author: lattner
> Date: Thu Aug 30 01:17:34 2007
> New Revision: 41602
>
> URL: http://llvm.org/viewvc/llvm-project?rev=41602&view=rev
> Log:
> Teach the stmtdumper to dump location/range info when a SourceMgr
> is available.
> For example, -parse-ast-dump now prints:
>
> static inline int __inline_isinff(float __x)
> (CompoundStmt 0x2409a20
> (ReturnStmt 0x2409a10
> (BinaryOperator 0x24099f0 'int' <///usr/include/architecture/
> i386/math.h:183:63, col:102> '=='
> (CallExpr 0x24098f0 'float' <col:63, col:82>
> (ImplicitCastExpr 0x24098e0 'float (*)(float)' <col:63>
> (DeclRefExpr 0x2409880 'float (float)' <col:63>
> Decl='__builtin_fabsf' 0x2409840))
> (DeclRefExpr 0x24098a0 'float' <col:79> Decl='__x' 0x2409810))
> (CallExpr 0x24099c0 'float' <col:87, col:102>
> (ImplicitCastExpr 0x2409870 'float (*)(void)' <col:87>
> (DeclRefExpr 0x2409980 'float (void)' <col:87>
> Decl='__builtin_inff' 0x2409940))))))
>
> where it only prints filename/line# if it changes from the previous
> value.
This is great. Thanks for adding this.
> We really need loc info on stmts though, like we have on exprs.
>
I can look @ adding statements if you'd like.
snaroff
More information about the cfe-commits
mailing list