mirror of https://github.com/golang/go.git
spec: add () to method calls in examples
Since p.M is rejected (must call methods), use p.M(), to keep the examples compiling. Fixes #4441. R=gri CC=golang-dev https://golang.org/cl/6854096
This commit is contained in:
parent
54023a94a6
commit
d4f3185c24
|
|
@ -1,6 +1,6 @@
|
|||
<!--{
|
||||
"Title": "The Go Programming Language Specification",
|
||||
"Subtitle": "Version of November 21, 2012",
|
||||
"Subtitle": "Version of November 26, 2012",
|
||||
"Path": "/ref/spec"
|
||||
}-->
|
||||
|
||||
|
|
@ -2463,9 +2463,9 @@ p.z // (*p).z
|
|||
p.y // ((*p).T1).y
|
||||
p.x // (*(*p).T0).x
|
||||
|
||||
p.M2 // (*p).M2
|
||||
p.M1 // ((*p).T1).M1
|
||||
p.M0 // ((*p).T0).M0
|
||||
p.M2() // (*p).M2()
|
||||
p.M1() // ((*p).T1).M1()
|
||||
p.M0() // ((*p).T0).M0()
|
||||
</pre>
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue