(module new_counter_user_adt (data Counter (ctor MkCounter (con Int))) (fn new (type (fn-type (params (con Int)) (ret (con Counter)))) (params n) (body (term-ctor Counter MkCounter n))) (fn main (type (fn-type (params) (ret (con Unit)) (effects IO))) (params) (body (let c (new Counter 42) (do io/print_str "ok\n")))))