Hi Eli,

Thanks again for taking your time to review my patch!

2012/10/19 Eli Friedman <[email protected]>:
> +  if (var->isThisDeclarationADefinition() &&
> +      (var->getLinkage() == ExternalLinkage ||
> +      var->getLinkage() == UniqueExternalLinkage)) {
>
> We don't want to warn for code like the following, which is what
> UniqueExternalLinkage is used for:
>
> namespace {
>   int x;
> }

The problem is that if I don't check for UniqueExternalLinkage, it
won't trigger a warning for this code, even though it should:

struct {
  int foo;
} bar;

-- 
Ed Schouten <[email protected]>
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to