summaryrefslogtreecommitdiffstats
path: root/llvm/examples/Kaleidoscope/Chapter9
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2017-12-20 19:36:54 +0000
committerDavid Blaikie <dblaikie@gmail.com>2017-12-20 19:36:54 +0000
commit870bbdb90bd4db395407ba95844dabcfc8e66a2e (patch)
tree1db6573f1f83ba500ea0a43865d71baf16b1c413 /llvm/examples/Kaleidoscope/Chapter9
parent8ec5632521e7e60b825440a6fad5d077316e0ba7 (diff)
downloadbcm5719-llvm-870bbdb90bd4db395407ba95844dabcfc8e66a2e.tar.gz
bcm5719-llvm-870bbdb90bd4db395407ba95844dabcfc8e66a2e.zip
PR35705: Fix Chapter 9 example code for API changes to DIBuilder
llvm-svn: 321214
Diffstat (limited to 'llvm/examples/Kaleidoscope/Chapter9')
-rw-r--r--llvm/examples/Kaleidoscope/Chapter9/toy.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/examples/Kaleidoscope/Chapter9/toy.cpp b/llvm/examples/Kaleidoscope/Chapter9/toy.cpp
index 1b13e45ec46..821cf4d25a6 100644
--- a/llvm/examples/Kaleidoscope/Chapter9/toy.cpp
+++ b/llvm/examples/Kaleidoscope/Chapter9/toy.cpp
@@ -823,7 +823,7 @@ DIType *DebugInfo::getDoubleTy() {
if (DblTy)
return DblTy;
- DblTy = DBuilder->createBasicType("double", 64, 64, dwarf::DW_ATE_float);
+ DblTy = DBuilder->createBasicType("double", 64, dwarf::DW_ATE_float);
return DblTy;
}
@@ -1436,7 +1436,8 @@ int main() {
// Currently down as "fib.ks" as a filename since we're redirecting stdin
// but we'd like actual source locations.
KSDbgInfo.TheCU = DBuilder->createCompileUnit(
- dwarf::DW_LANG_C, "fib.ks", ".", "Kaleidoscope Compiler", 0, "", 0);
+ dwarf::DW_LANG_C, DBuilder->createFile("fib.ks", "."),
+ "Kaleidoscope Compiler", 0, "", 0);
// Run the main "interpreter loop" now.
MainLoop();
OpenPOWER on IntegriCloud