Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/geektutu/high-performance-go
/ Add
Method
Add
charpter-2/code/hpg-empty-struct/main_set.go:12–14 ·
view source on GitHub ↗
(key string)
Source
from the content-addressed store, hash-verified
10
}
11
12
func
(s Set) Add(key string) {
13
s[key] =
struct
{}{}
14
}
15
16
func
(s Set) Delete(key string) {
17
delete(s, key)
Callers
4
benchmark
Function · 0.80
main
Function · 0.80
main
Function · 0.80
main
Function · 0.80
Calls
no outgoing calls
Tested by
1
benchmark
Function · 0.64