[PATCH] Store paren locations in IfStmt, WhileStmt, SwitchStmt.

Alexander Kornienko alexfh at google.com
Mon Sep 29 10:42:03 PDT 2014


Hi rsmith,

Storing the locations of parentheses in the if/while/switch statements
makes it much more straightforward for the tools (e.g. clang-tidy checks) to
operate on these locations. On the other hand, this increases memory usage
somewhat. I'm not sure what the right tradeoff here is, but my gut feeling is
that memory becomes cheaper, while developers' time doesn't.

http://reviews.llvm.org/D5528

Files:
  include/clang/AST/Stmt.h
  include/clang/Parse/Parser.h
  include/clang/Sema/Sema.h
  lib/AST/Stmt.cpp
  lib/Analysis/BodyFarm.cpp
  lib/Parse/ParseStmt.cpp
  lib/Sema/SemaStmt.cpp
  lib/Sema/TreeTransform.h
  lib/Serialization/ASTReaderStmt.cpp
  lib/Serialization/ASTWriterStmt.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D5528.14179.patch
Type: text/x-patch
Size: 21451 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140929/78458728/attachment.bin>


More information about the cfe-commits mailing list