Releases: CodeChain-io/intertrait
Releases · CodeChain-io/intertrait
Deal w/ bindings of associated types in trait impl
Code/doc and macro output improvement
This release is a minor update:
- Some code and doc cleanups
- Dependency constraints have been lessened by specifying up to minor version constraints
- Macro outputs have been improved not to cause problems in various contexts (mainly using
::<crate>
in paths rather than<crate>
Revamp APIs and support `Rc` and `Arc`
This release is incompatible with the previous 0.1.x
ones, and completely revamped the APIs for beter ergonomics. The highlights are:
- Support
Rc
andArc
- For
Arc
, the underlying type must beSync + Send
, useCastFromSync
instead ofCastFrom
and add[sync]
flag right before the list of traits in macros
- For
- All casts use methods with the same name,
cast
(that is,cast
is an overloaded name)- Separate traits are defined for each receiver type requireing casts
- Casts for
Box
,Rc
, andArc
returnResult
instead ofOption
to give the original receiver back on failure- This was the original design and returning
Option
was a bug in API design
- This was the original design and returning
Minor polish-ups
linkme
is upgraded to0.2.1
andintertrait
leverages its new shorthand notation for functions in the macro outputs- Documentations are a bit polished up
- Upgrade
trybuild
to1.0.25