Results 1846 comments of Steven Allen

> The with removing the identity feature is that libp2p (https://github.com/libp2p/rust-libp2p/blob/5291011c73f8eaf44b3ba4ada873d888ff26e703/core/Cargo.toml#L26) and Forest (https://github.com/ChainSafe/forest/blob/e708777ff6d28aa08ff47560cd62212dfe2fbbb7/node/forest_libp2p/Cargo.toml#L24) are using it atm. My point is that the current implementation is horribly broken and nobody...

> To me the usual use case, that also [libp2p is using](https://github.com/libp2p/rust-libp2p/blob/96103ee590b60d5c7ed7ca5253a7f7ddd802ce76/core/src/peer_id.rs#L60-L66) is "is the data smaller than a certain size, use the data directly, else hash it". In that...

@vmx so, that brings up an interesting question. The first two are "safe" (except for the identity hash) because we know the digests will fit. But the last one isn't...

For now I'm returning a result.

You know what, I think I have a good solution. I'm going to codegen tests.

So, actually, what I _can_ do is: 1. Have hashers specify a maximum digest size. 2. Statically assert that the maximum digest size of all hashers is less than the...

I mean at compile time. I can't remember exactly what I was planning, but I _think_ it was something like: when deriving `MultihashDigest`, emit some static assertions that `Digest::SIZE

> While testing the std/core2 expansion, I found out that core2 does support io::copy only on nightly Rust. @Stebalien is that a problem? Hm. Yes, it is. Especially because the...

Here's an example of a hack I've needed to prevent code that should "just work" from potentially crashing. I understand that downstream crates should generally use custom `Code` implementations, but...