[llvm] fb95b8d - [Kaleidoscope] Fix DWARF function creation example
    David Blaikie via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Mon Jul 25 11:20:17 PDT 2022
    
    
  
Author: Justin Brooks
Date: 2022-07-25T18:19:59Z
New Revision: fb95b8dc350ea84cf51b5f65aaaf1a5146ff3e47
URL: https://github.com/llvm/llvm-project/commit/fb95b8dc350ea84cf51b5f65aaaf1a5146ff3e47
DIFF: https://github.com/llvm/llvm-project/commit/fb95b8dc350ea84cf51b5f65aaaf1a5146ff3e47.diff
LOG: [Kaleidoscope] Fix DWARF function creation example
The full code listing was fixed in fdaeb0c647eb66763721a7fe74e0a36b007dcd75
Reviewed By: dblaikie
Differential Revision: https://reviews.llvm.org/D130217
Added: 
    
Modified: 
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
Removed: 
    
################################################################################
diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
index e74bf9b950a4f..37c234f2b3ff3 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
@@ -262,8 +262,9 @@ information) and construct our function definition:
   DISubprogram *SP = DBuilder->createFunction(
       FContext, P.getName(), StringRef(), Unit, LineNo,
       CreateFunctionType(TheFunction->arg_size()),
-      false /* internal linkage */, true /* definition */, ScopeLine,
-      DINode::FlagPrototyped, false);
+      ScopeLine,
+      DINode::FlagPrototyped,
+      DISubprogram::SPFlagDefinition);
   TheFunction->setSubprogram(SP);
 
 and we now have an DISubprogram that contains a reference to all of our
        
    
    
More information about the llvm-commits
mailing list