---------------------------------------------- lines 6-58 of file: xrst/comment_ch_command.py ---------------------------------------------- {xrst_begin comment_ch_cmd user} Comment Character Command ######################### Syntax ****** ``\{xrst_comment_ch`` *ch* ``}`` Purpose ******* Some languages have a special character that indicates the rest of the line is a comment. If you embed sphinx documentation in this type of comment, you need to inform xrst of the special character so it does not end up in your ``.rst`` output file. ch ** The value of *ch* must be one non white space character. There must be at least one white space character between ``xrst_comment_ch`` and *ch*. Leading and trailing white space around *ch* is ignored. Input Stream ************ Spaces and tabs before the special character, the special character, and one space directory after the special character (if present), are removed from the input stream before any xrst processing. For example, if :code:`#` is the special character, the following input has the heading Factorial and the ``def`` token indented the same amount: .. code-block:: py # Factorial # --------- def factorial(n) : if n == 1 : return 1 return n * factorial(n-1) Indentation *********** The :ref:`indent commands` are processed before removing the special character and its white space. Example ******* :ref:`comment_ch_example-name` {xrst_end comment_ch_cmd}