mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
fix example compact
adjust the date(Oct 7 2020 -> Feb 2 2021)
This commit is contained in:
parent
5a65aff7c3
commit
b34fffb6bb
1 changed files with 2 additions and 7 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
<!--{
|
<!--{
|
||||||
"Title": "The Go Programming Language Specification",
|
"Title": "The Go Programming Language Specification",
|
||||||
"Subtitle": "Version of Oct 7, 2020",
|
"Subtitle": "Version of Feb 2, 2021",
|
||||||
"Path": "/ref/spec"
|
"Path": "/ref/spec"
|
||||||
}-->
|
}-->
|
||||||
|
|
||||||
|
|
@ -3400,12 +3400,7 @@ A type assertion used in an <a href="#Assignments">assignment</a> or initializat
|
||||||
v, ok = x.(T)
|
v, ok = x.(T)
|
||||||
v, ok := x.(T)
|
v, ok := x.(T)
|
||||||
var v, ok = x.(T)
|
var v, ok = x.(T)
|
||||||
|
var v, ok interface{} = x.(T) // dynamic types of v and ok are T and bool
|
||||||
var v, ok interface{} = x.(T)
|
|
||||||
|
|
||||||
type v T
|
|
||||||
type ok T1
|
|
||||||
v, ok = x.(T) // type T1 is derived from interface{} or bool
|
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue