Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/adonovan/gopl.io
/ Example_struct
Function
Example_struct
ch12/display/display_test.go:60–66 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
58
}
59
60
func
Example_struct() {
61
Display(
"x"
,
struct
{ x
interface
{} }{3})
62
// Output:
63
// Display x (struct { x interface {} }):
64
// x.x.type = int
65
// x.x.value = 3
66
}
67
68
func
Example_interface() {
69
var
i
interface
{} = 3
Callers
nothing calls this directly
Calls
1
Display
Function · 0.85
Tested by
no test coverage detected