diff --git a/lib/AsmParser/LLLexer.cpp b/lib/AsmParser/LLLexer.cpp index 3c74c26f55a..99989ac971b 100644 --- a/lib/AsmParser/LLLexer.cpp +++ b/lib/AsmParser/LLLexer.cpp @@ -833,7 +833,7 @@ lltok::Kind LLLexer::LexDigitOrNegative() { } } - APFloatVal = APFloat(atof(TokStart)); + APFloatVal = APFloat(std::atof(TokStart)); return lltok::APFloat; } @@ -867,6 +867,6 @@ lltok::Kind LLLexer::LexPositive() { } } - APFloatVal = APFloat(atof(TokStart)); + APFloatVal = APFloat(std::atof(TokStart)); return lltok::APFloat; } diff --git a/lib/Target/SubtargetFeature.cpp b/lib/Target/SubtargetFeature.cpp index b35190a369e..ba53d63a91c 100644 --- a/lib/Target/SubtargetFeature.cpp +++ b/lib/Target/SubtargetFeature.cpp @@ -162,7 +162,7 @@ static void Help(const SubtargetFeatureKV *CPUTable, size_t CPUTableSize, errs() << "Use +feature to enable a feature, or -feature to disable it.\n" << "For example, llc -mcpu=mycpu -mattr=+feature1,-feature2\n"; - exit(1); + std::exit(1); } //===----------------------------------------------------------------------===// diff --git a/lib/Target/TargetInstrInfo.cpp b/lib/Target/TargetInstrInfo.cpp index eca97ab0966..d4986d89ddc 100644 --- a/lib/Target/TargetInstrInfo.cpp +++ b/lib/Target/TargetInstrInfo.cpp @@ -164,7 +164,7 @@ unsigned TargetInstrInfo::getInlineAsmLength(const char *Str, for (; *Str; ++Str) { if (*Str == '\n' || *Str == MAI.getSeparatorChar()) atInsnStart = true; - if (atInsnStart && !isspace(*Str)) { + if (atInsnStart && !std::isspace(*Str)) { Length += MAI.getMaxInstLength(); atInsnStart = false; } diff --git a/lib/VMCore/LLVMContext.cpp b/lib/VMCore/LLVMContext.cpp index 0f51cf224d0..c948320c20e 100644 --- a/lib/VMCore/LLVMContext.cpp +++ b/lib/VMCore/LLVMContext.cpp @@ -110,12 +110,12 @@ static bool isValidName(StringRef MDName) { if (MDName.empty()) return false; - if (!isalpha(MDName[0])) + if (!std::isalpha(MDName[0])) return false; for (StringRef::iterator I = MDName.begin() + 1, E = MDName.end(); I != E; ++I) { - if (!isalnum(*I) && *I != '_' && *I != '-' && *I != '.') + if (!std::isalnum(*I) && *I != '_' && *I != '-' && *I != '.') return false; } return true;