Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/adonovan/gopl.io
/ Example_interface
Function
Example_interface
ch12/display/display_test.go:68–74 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
66
}
67
68
func
Example_interface() {
69
var
i
interface
{} = 3
70
Display(
"i"
, i)
71
// Output:
72
// Display i (int):
73
// i = 3
74
}
75
76
func
Example_ptrToInterface2() {
77
var
i
interface
{} = 3
Callers
nothing calls this directly
Calls
1
Display
Function · 0.85
Tested by
no test coverage detected