16 lines
170 B
Go
16 lines
170 B
Go
package main
|
|
|
|
import "fmt"
|
|
|
|
func f() interface{} {
|
|
return make(map[int]int)
|
|
}
|
|
|
|
func main() {
|
|
a, ok := f().(map[int]int)
|
|
fmt.Println(a, ok)
|
|
}
|
|
|
|
// Output:
|
|
// map[] true
|