Skip to content

Commit

Permalink
Fix bitstring order in precise GC docs
Browse files Browse the repository at this point in the history
  • Loading branch information
anuraaga committed Oct 13, 2023
1 parent 75bba42 commit f7f58ff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/runtime/gc_precise.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@
// | object type | size | bitstring | note
// |-------------|------|-----------|------
// | int | 1 | 0 | no pointers in this object
// | string | 2 | 10 | {pointer, len} pair so there is one pointer
// | []int | 3 | 100 | {pointer, len, cap}
// | string | 2 | 01 | {pointer, len} pair so there is one pointer
// | []int | 3 | 001 | {pointer, len, cap}
// | [4]*int | 1 | 1 | even though it contains 4 pointers, an array repeats so it can be stored with size=1
// | [30]byte | 1 | 0 | there are no pointers so the layout is very simple
//
Expand Down

0 comments on commit f7f58ff

Please sign in to comment.