On Nov 19, 2010, at 2:30 PM, Abramo Bagnara wrote: > Il 19/11/2010 21:54, Argyrios Kyrtzidis ha scritto: >> Author: akirtzidis >> Date: Fri Nov 19 14:54:25 2010 >> New Revision: 119838 >> >> URL: http://llvm.org/viewvc/llvm-project?rev=119838&view=rev >> Log: >> Don't warn for empty 'if' body if there is a macro that expands to nothing, >> e.g: >> >> if (condition) >> CALL(0); // empty macro but don't warn for empty body. > > Is not this approach way too much ad hoc, is it?
Currently this is only useful for the 'if' body and was the simplest approach. > > What about loop body, else stmt and who knows how many places we might > be interested... > > Is not better to have the flag in NullStmt or to use another way to > detect this situation? > What are the use cases you have in mind ? Just checking if a NullStmt was preceded by an empty macro (not caring exactly which one) ? I'd prefer not to increase complexity without actual uses. -Argiris _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
