use std use thread type rwlock = struct _rcount : uint32 ;; const main = { var r : rwlock = [._rcount = 0] foo(r) foo(r) } const foo = {r if r._rcount++ == 0 std.put("you should only see this once\n") ;; }