[llvm] r226750 - Explicitly describe '///' versus '//' comment delimiters.
Paul Robinson
paul_robinson at playstation.sony.com
Wed Jan 21 16:19:58 PST 2015
Author: probinson
Date: Wed Jan 21 18:19:56 2015
New Revision: 226750
URL: http://llvm.org/viewvc/llvm-project?rev=226750&view=rev
Log:
Explicitly describe '///' versus '//' comment delimiters.
Modified:
llvm/trunk/docs/CodingStandards.rst
Modified: llvm/trunk/docs/CodingStandards.rst
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/CodingStandards.rst?rev=226750&r1=226749&r2=226750&view=diff
==============================================================================
--- llvm/trunk/docs/CodingStandards.rst (original)
+++ llvm/trunk/docs/CodingStandards.rst Wed Jan 21 18:19:56 2015
@@ -251,7 +251,8 @@ The next section in the file is a concis
file is released under. This makes it perfectly clear what terms the source
code can be distributed under and should not be modified in any way.
-The main body is a ``doxygen`` comment describing the purpose of the file. It
+The main body is a ``doxygen`` comment (identified by the ``///`` comment
+marker instead of the usual ``//``) describing the purpose of the file. It
should have a ``\brief`` command that describes the file in one or two
sentences. Any additional information should be separated by a blank line. If
an algorithm is being implemented or something tricky is going on, a reference
@@ -281,7 +282,8 @@ happens: does the method return null? A
Comment Formatting
^^^^^^^^^^^^^^^^^^
-In general, prefer C++ style (``//``) comments. They take less space, require
+In general, prefer C++ style comments (``//`` for normal comments, ``///`` for
+``doxygen`` documentation comments). They take less space, require
less typing, don't have nesting problems, etc. There are a few cases when it is
useful to use C style (``/* */``) comments however:
More information about the llvm-commits
mailing list