you can do early returns in ocaml by throwing exceptions and catching them, which is what `Core.with_return` does