зеркало из https://github.com/microsoft/clang-1.git
Look through SubstNonTypeTemplateParmExpr nodes in the various
Expr::Ignore* methods that also look through implicit casts. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139303 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Родитель
ed9d84a211
Коммит
c0244c5c35
|
@ -2042,7 +2042,11 @@ Expr *Expr::IgnoreParenCasts() {
|
|||
E = Materialize->GetTemporaryExpr();
|
||||
continue;
|
||||
}
|
||||
|
||||
if (SubstNonTypeTemplateParmExpr *NTTP
|
||||
= dyn_cast<SubstNonTypeTemplateParmExpr>(E)) {
|
||||
E = NTTP->getReplacement();
|
||||
continue;
|
||||
}
|
||||
return E;
|
||||
}
|
||||
}
|
||||
|
@ -2076,6 +2080,10 @@ Expr *Expr::IgnoreParenLValueCasts() {
|
|||
= dyn_cast<MaterializeTemporaryExpr>(E)) {
|
||||
E = Materialize->GetTemporaryExpr();
|
||||
continue;
|
||||
} else if (SubstNonTypeTemplateParmExpr *NTTP
|
||||
= dyn_cast<SubstNonTypeTemplateParmExpr>(E)) {
|
||||
E = NTTP->getReplacement();
|
||||
continue;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -2110,6 +2118,11 @@ Expr *Expr::IgnoreParenImpCasts() {
|
|||
E = Materialize->GetTemporaryExpr();
|
||||
continue;
|
||||
}
|
||||
if (SubstNonTypeTemplateParmExpr *NTTP
|
||||
= dyn_cast<SubstNonTypeTemplateParmExpr>(E)) {
|
||||
E = NTTP->getReplacement();
|
||||
continue;
|
||||
}
|
||||
return E;
|
||||
}
|
||||
}
|
||||
|
@ -2167,6 +2180,12 @@ Expr *Expr::IgnoreParenNoopCasts(ASTContext &Ctx) {
|
|||
}
|
||||
}
|
||||
|
||||
if (SubstNonTypeTemplateParmExpr *NTTP
|
||||
= dyn_cast<SubstNonTypeTemplateParmExpr>(E)) {
|
||||
E = NTTP->getReplacement();
|
||||
continue;
|
||||
}
|
||||
|
||||
return E;
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче