Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Alexandre Oliva
On Jul 17, 2019, Martin Sebor wrote: > Sure, if it's worthwhile to you I think it's an improvement even > if it doesn't fix a bug. (In full disclosure I'm not empowered > to formally approve bigger patches but I think cleanups like this > can safely be committed as obvious.) Thanks, I'm install

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Martin Sebor
On 7/17/19 1:14 PM, Alexandre Oliva wrote: On Jul 17, 2019, Martin Sebor wrote: Isn't this test sufficient to avoid the problems? if (!k && kmax > 1) continue; It is, unless someone (i) doesn't realize attributes that are present in the type can't be present

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Alexandre Oliva
On Jul 17, 2019, Martin Sebor wrote: > Isn't this test sufficient to avoid the problems? > if (!k && kmax > 1) > continue; It is, unless someone (i) doesn't realize attributes that are present in the type can't be present in the decl, (ii) misreads the '!k' as just 'k'

Re: -Wmissing-attributes: avoid duplicates and false positives

2019-07-17 Thread Martin Sebor
On 7/17/19 12:02 AM, Alexandre Oliva wrote: Hello, Martin, The initial patch for PR 81824 fixed one of the possibilities of -Wmissing-attributes reporting duplicates, namely, if TMPL had an attribute in ATTRLIST that was missing from DECL's decl and type attribute lists, both being non-empty. A