X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=examples%2FKaleidoscope%2FChapter6%2Ftoy.cpp;h=4d04f7e888af592e92d7da355e2a75aa46b5097b;hb=d16725c31fbb40fcbf0cdf68b2b417ba445c5140;hp=0b4ef3dbb9801749407bec0b165205b5782cf59d;hpb=23662fba704e684f24d3114bb399c80d5c0afbd9;p=oota-llvm.git diff --git a/examples/Kaleidoscope/Chapter6/toy.cpp b/examples/Kaleidoscope/Chapter6/toy.cpp index 0b4ef3dbb98..4d04f7e888a 100644 --- a/examples/Kaleidoscope/Chapter6/toy.cpp +++ b/examples/Kaleidoscope/Chapter6/toy.cpp @@ -90,7 +90,7 @@ static int gettok() { LastChar = getchar(); } while (isdigit(LastChar) || LastChar == '.'); - NumVal = strtod(NumStr.c_str(), 0); + NumVal = strtod(NumStr.c_str(), nullptr); return tok_number; } @@ -275,6 +275,7 @@ std::unique_ptr Error(const char *Str) { fprintf(stderr, "Error: %s\n", Str); return nullptr; } + std::unique_ptr ErrorP(const char *Str) { Error(Str); return nullptr;