From b6aa69ae31ec78fc41cec5b8f705761d3bb2a8bd Mon Sep 17 00:00:00 2001 From: Zhongxing Xu Date: Tue, 10 Nov 2009 08:33:44 +0000 Subject: [PATCH] Ignore parentheses when check the type of the expr. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86677 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Analysis/CheckSizeofPointer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Analysis/CheckSizeofPointer.cpp b/lib/Analysis/CheckSizeofPointer.cpp index 1aab3c973d..174beefbca 100644 --- a/lib/Analysis/CheckSizeofPointer.cpp +++ b/lib/Analysis/CheckSizeofPointer.cpp @@ -54,7 +54,7 @@ void WalkAST::VisitSizeOfAlignOfExpr(SizeOfAlignOfExpr *E) { // because people know what they are doing when they intentionally // dereference the pointer. Expr *ArgEx = E->getArgumentExpr(); - if (!isa(ArgEx)) + if (!isa(ArgEx->IgnoreParens())) return; SourceRange R = ArgEx->getSourceRange(); -- 2.50.1