You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Const-Generics:sp-multihash is on rust 1.54-nightly, so we were able to adapt @mriise's excellent const generics #116. It looks like you guys are waiting on 🔬 Tracking issue for generic associated types (GAT) rust-lang/rust#44265 hitting stable Rust first before merging const generics #116. To me, the usability regression reported in this comment seems acceptable compared to the usability gains from not having to drag typenums around everywhere. Plus, const-generics also opens up some really exciting refactoring possiblities, like @Stebalien's neat idea for using DSTs to erase the size-info here: Unsized Cids argumentcomputer/sp-cid#5. Since waiting some weeks/months for stable GATs seems not ideal, I'm wondering if we can figure out some way around this:
Is the stable requirement an absolute for this lib? Or maybe we could make a "nightly" rust-multihash branch/release so that development here isn't impacted by rustc as much?
Alternatively, is there a way to make the above usability regression acceptable to you, using only stable const-generics?
ByteCursor: Our no_std work removes std::io functions for reading/writing in favor of our bytecursor library. This can be added independently of Const-Generics.
Is the bytecursor dependency acceptable here? What about sp-std?
Do you want to keep the std::io, functions gated behind the std feature via pragmas? If so, should std still be default?
Hi, I talked briefly to @Stebalien about merging some of the work from our https://github.com/yatima-inc/sp-multihash no_std fork. Happy to send PRs, but wanted to ask a few questions first:
sp-multihashis on rust 1.54-nightly, so we were able to adapt @mriise's excellent const generics #116. It looks like you guys are waiting on 🔬 Tracking issue for generic associated types (GAT) rust-lang/rust#44265 hitting stable Rust first before merging const generics #116. To me, the usability regression reported in this comment seems acceptable compared to the usability gains from not having to drag typenums around everywhere. Plus,const-genericsalso opens up some really exciting refactoring possiblities, like @Stebalien's neat idea for using DSTs to erase the size-info here: Unsized Cids argumentcomputer/sp-cid#5. Since waiting some weeks/months for stable GATs seems not ideal, I'm wondering if we can figure out some way around this:rust-multihashbranch/release so that development here isn't impacted by rustc as much?const-generics?no_stdwork removesstd::iofunctions for reading/writing in favor of our bytecursor library. This can be added independently of Const-Generics.sp-std?std::io, functions gated behind thestdfeature via pragmas? If so, shouldstdstill be default?sp-multihash, and can PR (independently of the above) to add one here (preview: https://github.com/yatima-inc/rust-multihash/pull/1/files), if that's of interest.