mirror of
https://github.com/hanzo-fi/numscript.git
synced 2026-10-30 20:54:52 +00:00
13 lines
170 B
Go
13 lines
170 B
Go
package builder
|
|
|
|
type pool[T comparable] struct {
|
|
nextId int
|
|
elems map[T]int
|
|
}
|
|
|
|
func newPool[T comparable]() pool[T] {
|
|
return pool[T]{
|
|
elems: make(map[T]int),
|
|
}
|
|
}
|