diff options
author | Chandler Carruth <chandlerc@gmail.com> | 2011-04-27 18:48:59 +0000 |
---|---|---|
committer | Chandler Carruth <chandlerc@gmail.com> | 2011-04-27 18:48:59 +0000 |
commit | ede9d33cdeb453c686d9403bb359b27f01d48ce2 (patch) | |
tree | 861b0e17487bbb0885fc565f99922c4c1a6ab26a /clang/lib/Sema/SemaChecking.cpp | |
parent | 39b3a1ef7f29218854a104c1361bc5bde7fcb8fb (diff) | |
download | bcm5719-llvm-ede9d33cdeb453c686d9403bb359b27f01d48ce2.tar.gz bcm5719-llvm-ede9d33cdeb453c686d9403bb359b27f01d48ce2.zip |
Heh, funny thing, 'void' isn't a POD type. Nice of us to suggest it to
silence this warning. ;]
Fixed that obvious bug and added a bit more testing as well.
llvm-svn: 130318
Diffstat (limited to 'clang/lib/Sema/SemaChecking.cpp')
-rw-r--r-- | clang/lib/Sema/SemaChecking.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp index 6b219612d14..7ee0eac370b 100644 --- a/clang/lib/Sema/SemaChecking.cpp +++ b/clang/lib/Sema/SemaChecking.cpp @@ -1810,7 +1810,7 @@ void Sema::CheckMemsetArguments(const CallExpr *Call) { QualType DestTy = Dest->getType(); if (const PointerType *DestPtrTy = DestTy->getAs<PointerType>()) { QualType PointeeTy = DestPtrTy->getPointeeType(); - if (!PointeeTy->isPODType()) { + if (!PointeeTy->isPODType() && !PointeeTy->isVoidType()) { DiagRuntimeBehavior( Dest->getExprLoc(), Dest, PDiag(diag::warn_non_pod_memset) |