Merge pull request #69 from aaraney/patch-2

Add link to runtime.hmap struct
This commit is contained in:
Teiva Harsanyi 2023-11-28 19:38:27 +01:00 committed by GitHub
commit 7ebb7b603f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -77,7 +77,7 @@ Each bucket is a fixed-size array of eight elements. In the case of an insertion
</figure>
Under the hood, a Go map is a pointer to a runtime.hmap struct. This struct contains multiple fields, including a B field, giving the number of buckets in the map:
Under the hood, a Go map is a pointer to a [runtime.hmap](https://github.com/golang/go/blob/0262ea1ff9ac3b9fd268a48fcaaa6811c20cbea2/src/runtime/map.go#L117-L131) struct. This struct contains multiple fields, including a B field, giving the number of buckets in the map:
```go
type hmap struct {