Silence more -Wnon-pod-memset given its current implementation. I may be

able to revert these based on a patch I'm working on, but no reason for
people to be spammed with warnings in the interim.

llvm-svn: 130394
This commit is contained in:
Chandler Carruth 2011-04-28 08:19:45 +00:00
parent 3f7b581e2f
commit 6e1f9babcd
3 changed files with 3 additions and 3 deletions

View File

@ -338,7 +338,7 @@ void TemplateArgument::print(const PrintingPolicy &Policy,
//===----------------------------------------------------------------------===//
TemplateArgumentLocInfo::TemplateArgumentLocInfo() {
memset(this, 0, sizeof(TemplateArgumentLocInfo));
memset((void*)this, 0, sizeof(TemplateArgumentLocInfo));
}
SourceRange TemplateArgumentLoc::getSourceRange() const {

View File

@ -173,7 +173,7 @@ CFGBlockValues::CFGBlockValues(const CFG &c) : cfg(c), vals(0) {
if (!n)
return;
vals = new std::pair<ValueVector*, ValueVector*>[n];
memset(vals, 0, sizeof(*vals) * n);
memset((void*)vals, 0, sizeof(*vals) * n);
}
CFGBlockValues::~CFGBlockValues() {

View File

@ -284,7 +284,7 @@ const Token &MacroArgs::getStringifiedArgument(unsigned ArgNo,
assert(ArgNo < NumUnexpArgTokens && "Invalid argument number!");
if (StringifiedArgs.empty()) {
StringifiedArgs.resize(getNumArguments());
memset(&StringifiedArgs[0], 0,
memset((void*)&StringifiedArgs[0], 0,
sizeof(StringifiedArgs[0])*getNumArguments());
}
if (StringifiedArgs[ArgNo].isNot(tok::string_literal))