[llvm] 63cf704 - [Docs] Try fixing the tutorial toctree

via llvm-commits llvm-commits at lists.llvm.org
Sat Nov 16 15:11:11 PST 2019


Author: kristina
Date: 2019-11-16T23:06:50Z
New Revision: 63cf7040814e3b190a3b5a65858d8d59ab47b74d

URL: https://github.com/llvm/llvm-project/commit/63cf7040814e3b190a3b5a65858d8d59ab47b74d
DIFF: https://github.com/llvm/llvm-project/commit/63cf7040814e3b190a3b5a65858d8d59ab47b74d.diff

LOG: [Docs] Try fixing the tutorial toctree

Unorphan the old tutorial and reference every page in the index
explicitly. This should hopefully make Sphinx generate correct
hyperlinks now.

Added: 
    

Modified: 
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl01.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl02.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl03.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl04.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl06.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl07.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl08.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl10.rst
    llvm/docs/tutorial/MyFirstLanguageFrontend/index.rst
    llvm/docs/tutorial/index.rst

Removed: 
    


################################################################################
diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl01.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl01.rst
index 8cf01c8e4b9b..71ba9322817e 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl01.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl01.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 =====================================================
 Kaleidoscope: Kaleidoscope Introduction and the Lexer
 =====================================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl02.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl02.rst
index dec9f36ed565..c07c3ab192b8 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl02.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl02.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ===========================================
 Kaleidoscope: Implementing a Parser and AST
 ===========================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl03.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl03.rst
index 5364b172ad91..9b6df015bbde 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl03.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl03.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ========================================
 Kaleidoscope: Code generation to LLVM IR
 ========================================
@@ -198,7 +196,7 @@ automatically provide each one with an increasing, unique numeric
 suffix. Local value names for instructions are purely optional, but it
 makes it much easier to read the IR dumps.
 
-`LLVM instructions <../../LangRef.html#instruction-reference>`_ are constrained by strict
+:doc:`LLVM instructions <LangRef>` are constrained by strict
 rules: for example, the Left and Right operators of an `add
 instruction <../../LangRef.html#add-instruction>`_ must have the same type, and the
 result type of the add must match the operand types. Because all values

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl04.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl04.rst
index b643ae583c36..24c2b0f1755f 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl04.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl04.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ==============================================
 Kaleidoscope: Adding JIT and Optimizer Support
 ==============================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst
index 725423f2d389..11ae79de3019 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl05.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ==================================================
 Kaleidoscope: Extending the Language: Control Flow
 ==================================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl06.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl06.rst
index a05ed0b1a3b1..dd3a3f171375 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl06.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl06.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ============================================================
 Kaleidoscope: Extending the Language: User-defined Operators
 ============================================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl07.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl07.rst
index 14501fdf643e..a30be9894c3a 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl07.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl07.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 =======================================================
 Kaleidoscope: Extending the Language: Mutable Variables
 =======================================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl08.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl08.rst
index bd730fea6935..82776006a80e 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl08.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl08.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ========================================
  Kaleidoscope: Compiling to Object Code
 ========================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
index 87584cdb394e..4cdecc3ff131 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl09.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ======================================
 Kaleidoscope: Adding Debug Information
 ======================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl10.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl10.rst
index 6d8a131509e0..dd7d54778982 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl10.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/LangImpl10.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ======================================================
 Kaleidoscope: Conclusion and other useful LLVM tidbits
 ======================================================

diff  --git a/llvm/docs/tutorial/MyFirstLanguageFrontend/index.rst b/llvm/docs/tutorial/MyFirstLanguageFrontend/index.rst
index dcf9d5814fbe..e1e477d57d2b 100644
--- a/llvm/docs/tutorial/MyFirstLanguageFrontend/index.rst
+++ b/llvm/docs/tutorial/MyFirstLanguageFrontend/index.rst
@@ -2,6 +2,20 @@
 My First Language Frontend with LLVM Tutorial
 =============================================
 
+.. toctree::
+   :hidden:
+
+   LangImpl01
+   LangImpl02
+   LangImpl03
+   LangImpl04
+   LangImpl05
+   LangImpl06
+   LangImpl07
+   LangImpl08
+   LangImpl09
+   LangImpl10
+
 **Requirements:** This tutorial assumes you know C++, but no previous
 compiler experience is necessary.
 
@@ -46,7 +60,8 @@ allowing you to skip ahead as you wish:
    One great thing about LLVM is its support for JIT compilation, so
    we'll dive right into it and show you the 3 lines it takes to add JIT
    support. Later chapters show how to generate .o files.
--  `Chapter #5: Extending the Language: Control Flow <LangImpl05.html>`_ - With the basic language up and running, we show how to extend
+-  `Chapter #5: Extending the Language: Control Flow <LangImpl05.html>`_ - With
+   the basic language up and running, we show how to extend
    it with control flow operations ('if' statement and a 'for' loop). This
    gives us a chance to talk about SSA construction and control
    flow.

diff  --git a/llvm/docs/tutorial/index.rst b/llvm/docs/tutorial/index.rst
index 1a5277de4d8c..8aa45184902d 100644
--- a/llvm/docs/tutorial/index.rst
+++ b/llvm/docs/tutorial/index.rst
@@ -6,14 +6,13 @@ Kaleidoscope: Implementing a Language with LLVM
 ===============================================
 
 .. toctree::
-   :titlesonly:
-   :glob:
-   :numbered:
+   :hidden:
 
    MyFirstLanguageFrontend/index
 
-This is the "Kaleidoscope" Language tutorial, showing how to implement a simple
-language using LLVM components in C++.
+:doc:`MyFirstLanguageFrontend/index`
+  This is the "Kaleidoscope" Language tutorial, showing how to implement a simple
+  language using LLVM components in C++.
 
 Kaleidoscope: Implementing a Language with LLVM in Objective Caml
 =================================================================


        


More information about the llvm-commits mailing list