Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-06 Thread Richard Smith via cfe-commits
On Wed, 5 Dec 2018 at 11:14, Alex L via cfe-commits < cfe-commits@lists.llvm.org> wrote: > We have about 100k unique occurrences of this warning across a slice of > our software stack. It's simply not feasible to us to adopt it, so we would > prefer for it to be reverted to avoid downstream

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread James Y Knight via cfe-commits
Nobody should be using "-Weverything" in their default build flags! It should only be used as a way to find the names of interesting warning flags. I'd note that "-Weverything" even has warnings that _conflict_ with each-other... It's unworkable for clang to have a policy which prevents the

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread Aaron Ballman via cfe-commits
On Wed, Dec 5, 2018 at 2:14 PM Alex L via cfe-commits wrote: > > We have about 100k unique occurrences of this warning across a slice of our > software stack. It's simply not feasible to us to adopt it, so we would > prefer for it to be reverted to avoid downstream divergence in Apple's clang.

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread Alex L via cfe-commits
We have about 100k unique occurrences of this warning across a slice of our software stack. It's simply not feasible to us to adopt it, so we would prefer for it to be reverted to avoid downstream divergence in Apple's clang. Granted, these occur in projects that use -Weverything but those

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread Richard Smith via cfe-commits
On Wed, 5 Dec 2018, 10:01 George Karpenkov via cfe-commits < cfe-commits@lists.llvm.org wrote: > These are the cases I get: > > #define unexpected(a) { kprintf("unexpected %s:%d\n", __FILE__, __LINE__); > a; } > > and > > #if 0 > #define DEBG(fmt, args...) { IOLog(fmt, ## args); kprintf(fmt,

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread George Karpenkov via cfe-commits
These are the cases I get: #define unexpected(a) { kprintf("unexpected %s:%d\n", __FILE__, __LINE__); a; } and #if 0 #define DEBG(fmt, args...) { IOLog(fmt, ## args); kprintf(fmt, ## args); } #else #define DEBG(fmt, args...) {} #endif Now calls `DEBG(‘x’);` and `unexpected(‘msg’);`

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-05 Thread Aaron Ballman via cfe-commits
On Wed, Dec 5, 2018 at 1:40 AM Roman Lebedev wrote: > > On Wed, Dec 5, 2018 at 4:07 AM Artem Dergachev via cfe-commits > wrote: > > > > > > > > On 12/4/18 5:04 PM, George Karpenkov via cfe-dev wrote: > > > > > >> On Dec 4, 2018, at 4:47 PM, Aaron Ballman wrote: > > >> > > >> On Tue, Dec 4, 2018

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-04 Thread Roman Lebedev via cfe-commits
On Wed, Dec 5, 2018 at 4:07 AM Artem Dergachev via cfe-commits wrote: > > > > On 12/4/18 5:04 PM, George Karpenkov via cfe-dev wrote: > > > >> On Dec 4, 2018, at 4:47 PM, Aaron Ballman wrote: > >> > >> On Tue, Dec 4, 2018 at 7:35 PM George Karpenkov > >> wrote: > >>> Hi Roman, Hi. > >>> I’m

Re: [cfe-dev] r347339 - [clang][Parse] Diagnose useless null statements / empty init-statements

2018-12-04 Thread Artem Dergachev via cfe-commits
On 12/4/18 5:04 PM, George Karpenkov via cfe-dev wrote: On Dec 4, 2018, at 4:47 PM, Aaron Ballman wrote: On Tue, Dec 4, 2018 at 7:35 PM George Karpenkov wrote: Hi Roman, I’m against this new warning. A very common idiom is defining a “DEBUG” macro to be a no-op in release, and a