diff options
Diffstat (limited to 'clang/lib/AST/ASTDiagnostic.cpp')
| -rw-r--r-- | clang/lib/AST/ASTDiagnostic.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/AST/ASTDiagnostic.cpp b/clang/lib/AST/ASTDiagnostic.cpp index 15e288acb9a..20540f3ce12 100644 --- a/clang/lib/AST/ASTDiagnostic.cpp +++ b/clang/lib/AST/ASTDiagnostic.cpp @@ -1184,7 +1184,8 @@ class TemplateDiff { } DeclRefExpr *DRE = dyn_cast<DeclRefExpr>(ArgExpr); if (!DRE) { - DRE = cast<DeclRefExpr>(cast<UnaryOperator>(ArgExpr)->getSubExpr()); + DRE = cast<DeclRefExpr>( + cast<UnaryOperator>(ArgExpr->IgnoreParens())->getSubExpr()); } return DRE->getDecl(); |

