Want to know what's even worse? Using comments for something <i>but not parsing the syntax tree</i>.<p>In go 1.4, save the following to a file and run 'go generate' on it: <a href="https://play.golang.org/p/9WJtxClRXr" rel="nofollow">https://play.golang.org/p/9WJtxClRXr</a> (I'd make it run in the playground, but you can't 'fork exec', so exec.Command($GOBIN, generate) won't work sadly)<p>Even though that code has no comments (only a multi-line string), go generate will run and print out a '\'.<p>I also used that generate command to point out that with generate, as it exists in 1.4, there's actually NO WAY to print out a dollar sign.<p>The dollar-sign part of this is fixed in master (so go1.5), but it was fixed not by allowing '\$', but by the bizarre $DOLLAR environment variable. See <a href="https://go-review.googlesource.com/#/c/8091/" rel="nofollow">https://go-review.googlesource.com/#/c/8091/</a><p>These "features" make the use of comments as directives even worse, because it's <i>NOT</i> comments being used as directives in the case of go generate, but simple string matching. It literally just loops through lines of text and checks if it startswith the correct substring.<p>This was, of course, done due to lazyness (same as $DOLLAR and many other 'features' of go), and the lazyness is starting to show through the cracks here and there.<p>Go often prefers pain for the programmer for the compiler developer's life being simpler by about 5 minutes.