commit 2ed94027ea02b9942fdf7a74a0d6ef277c7a1f12
parent 75e23a3629cfbfb134b76c1d1ff5aebf43aa103b
Author: Drew DeVault <sir@cmpwn.com>
Date: Tue, 4 May 2021 14:02:24 -0400
hare::types: document typestore design better
Signed-off-by: Drew DeVault <sir@cmpwn.com>
Diffstat:
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/hare/types/store.ha b/hare/types/store.ha
@@ -14,8 +14,12 @@ export type resolver = fn(
) (size | deferred | errors::opaque);
export type typestore = struct {
- arch: arch,
+ // This hash map provides the canonical address for all types owned by
+ // this type store. Any type which has a reference to another type has
+ // borrowed it from this map.
map: [BUCKETS][]_type,
+
+ arch: arch,
resolve: nullable *resolver,
rstate: nullable *void,
};