test an opaque record across a module boundary

A bodyless pub record ahead of a private definition exports the handle
and keeps the fields, the way flecs keeps ecs_world_t. It worked with
nothing added, and nothing said so.
This commit is contained in:
2026-10-08 11:09:42 +03:00
parent 6c8b38b7e2
commit e9960488fb
4 changed files with 33 additions and 3 deletions

View File

@@ -40,6 +40,13 @@
(.show-line v)
;; only the handle crossed: (. t n) here is an incomplete type
(var t (* tally) (tally/make))
(.bump t)
(.bump t)
(printf "tally %d\n" (.count t))
(.drop t)
(var c colour (colour/rgb 1 2 3))
(match c
((rgb (r g b)) (printf "colour %d%d%d\n" r g b))