(module bool_to_str_drop_rc (fn main (doc "Iter 24.1: pin that `bool_to_str` participates in RC discipline. Bind the heap-Str result to `s`, consume `s` once in `io/print_str`, let the binder drop at scope close. Under --alloc=rc with AILANG_RC_STATS=1 the atexit summary must report allocs == 1 && frees == 1 && live == 0 — the heap-Str slab allocated by str_alloc inside ailang_bool_to_str rides the same rc_header + ailang_rc_dec path as int_to_str.") (type (fn-type (params) (ret (own (con Unit))) (effects IO))) (params) (body (let s (app bool_to_str true) (seq (do io/print_str s) (do io/print_str "\n"))))))