MCPcopy
hub / github.com/adonovan/gopl.io

github.com/adonovan/gopl.io @main sqlite

repository ↗ · DeepWiki ↗
504 symbols 1,069 edges 163 files 233 documented · 46%
README

The Go Programming Language

This repository provides the downloadable example programs for the book, "The Go Programming Language"; see http://www.gopl.io.

These example programs are licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Creative Commons License

You can download, build, and run the programs with the following commands:

$ export GOPATH=$HOME/gobook            # choose workspace directory
$ go get gopl.io/ch1/helloworld         # fetch, build, install
$ $GOPATH/bin/helloworld                # run
Hello, 世界

Many of the programs contain comments of the form //!+ and //!-. These comments bracket the parts of the programs that are excerpted in the book; you can safely ignore them. In a few cases, programs have been reformatted in an unnatural way so that they can be presented in stages in the book.

Extension points exported contracts — how you extend this code

Expr (Interface)
An Expr is an arithmetic expression. [3 implementers]
ch7/eval/ast.go
M (Interface)
(no doc) [5 implementers]
ch9/memotest/memotest.go
Func (FuncType)
Func is the type of the function to memoize.
ch9/memo2/memo.go
Func (FuncType)
Func is the type of the function to memoize.
ch9/memo4/memo.go
Func (FuncType)
!+Func Func is the type of the function to memoize.
ch9/memo5/memo.go
Func (FuncType)
Func is the type of the function to memoize.
ch9/memo1/memo.go
Func (FuncType)
(no doc)
ch9/memo3/memo.go

Core symbols most depended-on inside this repo

Close
called by 30
ch9/memo5/memo.go
Get
called by 26
ch9/memotest/memotest.go
Add
called by 21
ch6/intset/intset.go
Display
called by 20
ch12/display/display.go
String
called by 17
ch7/http4/main.go
Eval
called by 17
ch7/eval/ast.go
Len
called by 11
ch7/sorting/main.go
Equal
called by 10
ch13/equal/equal.go

Shape

Function 343
Method 78
Struct 45
TypeAlias 31
FuncType 5
Interface 2

Languages

Go100%

Modules by API surface

ch7/sorting/main.go17 symbols
ch12/display/display_test.go15 symbols
ch9/memo5/memo.go11 symbols
ch7/eval/parse.go11 symbols
ch12/sexpr/pretty.go11 symbols
ch7/tempconv/tempconv.go8 symbols
ch7/eval/ast.go8 symbols
ch12/sexpr/decode.go8 symbols
ch8/thumbnail/thumbnail_test.go7 symbols
ch8/cake/cake.go7 symbols
ch2/popcount/popcount_test.go7 symbols
ch13/equal/equal_test.go7 symbols

Dependencies from manifests, versioned

golang.org/x/netv0.0.0-2021092919355 · 1×

For agents

$ claude mcp add gopl.io \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact