(module test_22b3_chained_calls
  (class B
    (param a)
    (method b_method
      (type (fn-type (params (own a)) (ret (own (con Int)))))))
  (class A
    (param a)
    (method a_method
      (type (fn-type (params (own a)) (ret (own (con Int)))))
      (default (lam (params (typed x a)) (ret (con Int)) (body (app b_method x))))))
  (instance
    (class B)
    (type (con Int))
    (method b_method
      (body (lam (params (typed y a)) (ret (con Int)) (body y)))))
  (instance
    (class A)
    (type (con Int)))
  (fn main
    (type (fn-type (params) (ret (own (con Int)))))
    (params)
    (body (app a_method 5))))
