(module test_22c_user_class_e2e (data IntBox (ctor MkIntBox (con Int))) (class Foo (param a) (method foo (type (fn-type (params (borrow a)) (ret (own (con Int))))))) (instance (class Foo) (type (con IntBox)) (method foo (body (lam (params (typed b a)) (ret (con Int)) (body (match b (case (pat-ctor MkIntBox v) v))))))) (fn main (type (fn-type (params) (ret (own (con Unit))) (effects IO))) (params) (body (app print (app foo (term-ctor IntBox MkIntBox 42))))))