X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=examples%2FKaleidoscope%2FChapter8%2Ftoy.cpp;h=7338c6ebc50bd15b86b686827031e96a64bb23b5;hb=38941a6a2067022a99d14daf0c8564ce5a0c131e;hp=b78d901db2d5fb5525b88dc88994b4074b35b87a;hpb=631949892f2618d37d0d9c19a50c7631a72ca0b8;p=oota-llvm.git diff --git a/examples/Kaleidoscope/Chapter8/toy.cpp b/examples/Kaleidoscope/Chapter8/toy.cpp index b78d901db2d..7338c6ebc50 100644 --- a/examples/Kaleidoscope/Chapter8/toy.cpp +++ b/examples/Kaleidoscope/Chapter8/toy.cpp @@ -1384,13 +1384,13 @@ static void MainLoop() { /// putchard - putchar that takes a double and returns 0. extern "C" double putchard(double X) { - fputc((char)X, stderr); + putchar((char)X); return 0; } /// printd - printf that takes a double prints it as "%f\n", returning 0. extern "C" double printd(double X) { - fprintf(stderr, "%f\n", X); + printf("%f\n", X); return 0; }