diff options
Diffstat (limited to 'clang/lib/Sema/SemaDecl.cpp')
| -rw-r--r-- | clang/lib/Sema/SemaDecl.cpp | 8 | 
1 files changed, 0 insertions, 8 deletions
| diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp index 5dbfa105e13..9c93e113125 100644 --- a/clang/lib/Sema/SemaDecl.cpp +++ b/clang/lib/Sema/SemaDecl.cpp @@ -1220,14 +1220,6 @@ bool Sema::ShouldWarnIfUnusedFileScopedDecl(const DeclaratorDecl *D) const {      if (!isMainFileLoc(*this, VD->getLocation()))        return false; -    // If a variable usable in constant expressions is referenced, -    // don't warn if it isn't used: if the value of a variable is required -    // for the computation of a constant expression, it doesn't make sense to -    // warn even if the variable isn't odr-used.  (isReferenced doesn't -    // precisely reflect that, but it's a decent approximation.) -    if (VD->isReferenced() && VD->isUsableInConstantExpressions(Context)) -      return false; -      if (Context.DeclMustBeEmitted(VD))        return false; | 

