From efcc50dfdc94c82ee0292bf71992ecb7c0123061 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Tue, 14 May 2013 18:39:35 +0200 Subject: Imported Upstream version 1.1 --- doc/articles/godoc_documenting_go_code.html | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'doc/articles/godoc_documenting_go_code.html') diff --git a/doc/articles/godoc_documenting_go_code.html b/doc/articles/godoc_documenting_go_code.html index 18a3ee953..3f4e3228c 100644 --- a/doc/articles/godoc_documenting_go_code.html +++ b/doc/articles/godoc_documenting_go_code.html @@ -83,18 +83,20 @@ godoc's output, with one notable exception. Top-level comments that begin with the word "BUG(who)" are recognized as known bugs, and included in the "Bugs" section of the package documentation. The "who" part should be the user name of someone who could provide more information. For example, this is a -known issue from the bytes package: +known issue from the sync/atomic package:

-// BUG(r): The rule Title uses for word boundaries does not handle Unicode punctuation properly.
+// BUG(rsc): On x86-32, the 64-bit functions use instructions
+// unavailable before the Pentium MMX. On both ARM and x86-32, it is the
+// caller's responsibility to arrange for 64-bit alignment of 64-bit
+// words accessed atomically.
 

-Godoc treats executable commands somewhat differently. Instead of inspecting the -command source code, it looks for a Go source file belonging to the special -package "documentation". The comment on the "package documentation" clause is -used as the command's documentation. For example, see the +Godoc treats executable commands in the same way. It looks for a comment on +package main, which is sometimes put in a separate file called doc.go. +For example, see the godoc documentation and its corresponding doc.go file.

-- cgit v1.2.3