forked from OSchip/llvm-project
[clang][sema] instantiateOMPDeclareVariantAttr - merge repeated VariantFuncRef.get() calls. NFCI.
Fixes scan-build warning about dead initialization
This commit is contained in:
parent
0ce3c7111e
commit
b577126d62
|
@ -436,11 +436,11 @@ static void instantiateOMPDeclareVariantAttr(
|
|||
return;
|
||||
|
||||
Expr *E = VariantFuncRef.get();
|
||||
|
||||
// Check function/variant ref for `omp declare variant` but not for `omp
|
||||
// begin declare variant` (which use implicit attributes).
|
||||
Optional<std::pair<FunctionDecl *, Expr *>> DeclVarData =
|
||||
S.checkOpenMPDeclareVariantFunction(S.ConvertDeclToDeclGroup(New),
|
||||
VariantFuncRef.get(), TI,
|
||||
S.checkOpenMPDeclareVariantFunction(S.ConvertDeclToDeclGroup(New), E, TI,
|
||||
Attr.getRange());
|
||||
|
||||
if (!DeclVarData)
|
||||
|
|
Loading…
Reference in New Issue