summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaStmtAsm.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2013-03-22 21:33:46 +0000
committerBill Wendling <isanbard@gmail.com>2013-03-22 21:33:46 +0000
commitb3b4a371387b68f3c2da0914fbac989e3e49572a (patch)
treed4a48a299c839cca2413ae31a5a6664d2343b380 /clang/lib/Sema/SemaStmtAsm.cpp
parent21c29e5713f3345773cd301c00c9f5b2b7f1ff53 (diff)
downloadbcm5719-llvm-b3b4a371387b68f3c2da0914fbac989e3e49572a.tar.gz
bcm5719-llvm-b3b4a371387b68f3c2da0914fbac989e3e49572a.zip
Use RequireCompleteType() instead of isIncompleteType().
isIncompleteType() returns true or false for template types depending on whether the type is instantiated yet. In this context, that's arbitrary. The better way to check for a complete type is RequireCompleteType(). Thanks to Eli Friedman for noticing this! <rdar://problem/12700799> llvm-svn: 177768
Diffstat (limited to 'clang/lib/Sema/SemaStmtAsm.cpp')
-rw-r--r--clang/lib/Sema/SemaStmtAsm.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaStmtAsm.cpp b/clang/lib/Sema/SemaStmtAsm.cpp
index 3e9606e467c..95964e20a7e 100644
--- a/clang/lib/Sema/SemaStmtAsm.cpp
+++ b/clang/lib/Sema/SemaStmtAsm.cpp
@@ -181,7 +181,9 @@ StmtResult Sema::ActOnGCCAsmStmt(SourceLocation AsmLoc, bool IsSimple,
InputConstraintInfos.push_back(Info);
const Type *Ty = Exprs[i]->getType().getTypePtr();
- if (Ty->isDependentType() || Ty->isIncompleteType())
+ if (Ty->isDependentType() ||
+ RequireCompleteType(InputExpr->getLocStart(),
+ Exprs[i]->getType(), 0))
continue;
unsigned Size = Context.getTypeSize(Ty);
OpenPOWER on IntegriCloud