[llvm-commits] [llvm] r170145 - /llvm/trunk/docs/SphinxQuickstartTemplate.rst

Sean Silva silvas at purdue.edu
Thu Dec 13 12:14:25 PST 2012


Author: silvas
Date: Thu Dec 13 14:14:25 2012
New Revision: 170145

URL: http://llvm.org/viewvc/llvm-project?rev=170145&view=rev
Log:
docs: Improve discussion of syntax highlighting.

Modified:
    llvm/trunk/docs/SphinxQuickstartTemplate.rst

Modified: llvm/trunk/docs/SphinxQuickstartTemplate.rst
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/SphinxQuickstartTemplate.rst?rev=170145&r1=170144&r2=170145&view=diff
==============================================================================
--- llvm/trunk/docs/SphinxQuickstartTemplate.rst (original)
+++ llvm/trunk/docs/SphinxQuickstartTemplate.rst Thu Dec 13 14:14:25 2012
@@ -107,17 +107,32 @@
      return 0
    }
 
-For a shell session, use a ``console`` code block:
+For a shell session, use a ``console`` code block (some existing docs use
+``bash``):
 
 .. code-block:: console
 
    $ echo "Goodbye cruel world!"
    $ rm -rf /
 
-If you need to show LLVM IR use the ``llvm`` code block.  Code blocks of ``c``,
-``c++``, ``objc``, ``bash``, ``makefile`` kinds are supported.
+If you need to show LLVM IR use the ``llvm`` code block.
 
-You can show preformatted text without any syntax highlighting like this:
+.. code-block:: llvm
+
+   define i32 @test1() {
+   entry:
+     ret i32 0
+   }
+
+Some other common code blocks you might need are ``c``, ``objc``, ``make``,
+and ``cmake``. If you need something beyond that, you can look at the `full
+list`_ of supported code blocks.
+
+.. _`full list`: http://pygments.org/docs/lexers/
+
+However, don't waste time fiddling with syntax highlighting when you could
+be adding meaningful content. When in doubt, show preformatted text
+without any syntax highlighting like this:
 
 ::
 
@@ -137,8 +152,6 @@
                          .++:..
                           ...
 
-One can also use a ``none`` code block to turn off highlighting.
-
 Hopefully you won't need to be this deep
 """"""""""""""""""""""""""""""""""""""""
 





More information about the llvm-commits mailing list