mirror of
https://github.com/golang/go
synced 2024-11-12 05:30:21 -07:00
forgot to update the body when i changed the receiver type.
R=rsc DELTA=2 (0 added, 0 deleted, 2 changed) OCL=35759 CL=35761
This commit is contained in:
parent
2119b3672d
commit
ee3e97c778
@ -1584,8 +1584,8 @@ But why make <code>Counter</code> a struct? An integer is all that's needed.
|
||||
type Counter int
|
||||
|
||||
func (ctr *Counter) ServeHTTP(c *http.Conn, req *http.Request) {
|
||||
ctr++;
|
||||
fmt.Fprintf(c, "counter = %d\n", ctr);
|
||||
*ctr++;
|
||||
fmt.Fprintf(c, "counter = %d\n", *ctr);
|
||||
}
|
||||
</pre>
|
||||
<p>
|
||||
|
Loading…
Reference in New Issue
Block a user