Recommit previous cleanup with a fix for c++98 ambiguity.

llvm-svn: 187752
This commit is contained in:
Eric Christopher 2013-08-05 22:32:28 +00:00
parent a96032b0e7
commit 77c487801a

View File

@ -988,11 +988,8 @@ static StringRef getDIEStringAttr(DIE *Die, unsigned Attr) {
/// a trailing NULL with the string.
static void addStringToHash(MD5 &Hash, StringRef Str) {
DEBUG(dbgs() << "Adding string " << Str << " to hash.\n");
HashValue SVal((const uint8_t *)Str.data(), Str.size());
const uint8_t NB = '\0';
HashValue NBVal((const uint8_t *)&NB, 1);
Hash.update(SVal);
Hash.update(NBVal);
Hash.update(Str);
Hash.update(makeArrayRef((uint8_t)'\0'));
}
// FIXME: These are copied and only slightly modified out of LEB128.h.