1
0
mirror of https://github.com/golang/go synced 2024-11-25 06:47:56 -07:00

doc: add reference to FAQ to explain warning about concrete type

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/5820048
This commit is contained in:
Stefan Nilsson 2012-03-15 09:15:16 +11:00 committed by Andrew Gerrand
parent c959ebe4d8
commit f00872527b

View File

@ -258,8 +258,9 @@ Next we modify the appHandler type to return <code>*appError</code> values:
<p> <p>
(It's usually a mistake to pass back the concrete type of an error rather than (It's usually a mistake to pass back the concrete type of an error rather than
<code>error</code>, for reasons to be discussed in another article, but <code>error</code>,
it's the right thing to do here because <code>ServeHTTP</code> is the only for reasons discussed in <a href="/doc/go_faq.html#nil_error">the Go FAQ</a>,
but it's the right thing to do here because <code>ServeHTTP</code> is the only
place that sees the value and uses its contents.) place that sees the value and uses its contents.)
</p> </p>