Expand description
§Notice
This crate has been moved/renamed to tryvial. You should use that instead.
Macro for stable try blocks that performs Ok-wrapping, and otherwise tries to
achieve feature parity with RFC 1859. The macro is compatible with any type
that implements the unstable Try
trait through the use of type magic.
This crate is no_std
compatible.
Macros§
- try_
block - Macro for the recieving end of a
?
operation. Right now, type inference is quite finicky so you usually have to declare a concrete type somewhere. - try_cf
- Like
try_block
, but specificially for [ControlFlow
]. This aids type inference. - try_opt
- Like
try_block
, but specificially forOption
. This aids type inference. - try_res
- Like
try_block
, but specificially forResult
]. This aids type inference. - wrap_ok
- Macro for ok-wrapping any
Try
type. This works on stable through dark type magic.