Re: [cfe-users] Should clang++ -g produce debugging info for all types?

2019-07-30 Thread Bob Eastbrook via cfe-users
On Thu, Jul 25, 2019 at 8:35 PM David Blaikie wrote: > No, it shouldn't - clang attempts to avoid emitting duplicate debug info > across the program (it assumes you built the whole program and all libraries > with debug info), gcc assumes the same thing though in slightly > different/fewer way

Re: [cfe-users] [clang-format] Trailing return type

2019-07-30 Thread Mateusz Loskot via cfe-users
On Mon, 5 Nov 2018 at 19:27, Mateusz Loskot wrote: > On Fri, 2 Nov 2018 at 06:11, Owen Pan wrote: > > I noticed one issue which I wonder if it does qualify for a bug report: > > TL;TR: arrow followed by typename keyword is not handled > > Before: > > template > auto bbb(detai

Re: [cfe-users] [clang-format] Trailing return type

2019-07-30 Thread Mateusz Loskot via cfe-users
On Wed, 31 Jul 2019 at 00:14, Mateusz Loskot wrote: > On Mon, 5 Nov 2018 at 19:27, Mateusz Loskot wrote: > > On Fri, 2 Nov 2018 at 06:11, Owen Pan wrote: > > > > I noticed one issue which I wonder if it does qualify for a bug report: > > > > TL;TR: arrow followed by typename keyword is not handl

[cfe-users] AST Recursive Visitor- Statements (Stmt *)

2019-07-30 Thread Ayush Mittal via cfe-users
Hello Clangers, I'm new to clang. I'm writing an AST Consumer plug-in to visit the statements node and record the data in one of my table with line numbers. I've this function callback ready: *VisitStmt(Stmt *S)*. My question is how could I traverse If, while, for loop, boolean and Unary Operators

Re: [cfe-users] AST Recursive Visitor- Statements (Stmt *)

2019-07-30 Thread Richard Trieu via cfe-users
Hi Ayush, First, you need to know the classes associated with each of your target AST nodes. These are IfStmt, WhileStmt, ForStmt, BinaryOperator, and UnaryOperator. Each of these are sub-classes of Stmt. IfStmt, WhileStmt, ForStmt and direct sub-classes while BinaryOperator and UnaryOperator a