forked from OSchip/llvm-project
Revert change accidentally committed in r191150.
llvm-svn: 191237
This commit is contained in:
parent
ccac5c4bf9
commit
0b5511971e
|
@ -3372,9 +3372,7 @@ void Sema::BuildVariableInstantiation(
|
|||
OldVar->isPreviousDeclInSameBlockScope());
|
||||
NewVar->setAccess(OldVar->getAccess());
|
||||
|
||||
// For local variables, inherit the 'used' and 'referenced' flags from the
|
||||
// primary template.
|
||||
if (OldVar->getLexicalDeclContext()->isFunctionOrMethod()) {
|
||||
if (!OldVar->isStaticDataMember()) {
|
||||
NewVar->setIsUsed(OldVar->isUsed(false));
|
||||
NewVar->setReferenced(OldVar->isReferenced());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue