GabrielDertoni
GabrielDertoni
As far as I can tell, `bytes` does support `no_std`, you can simply add `default_features = false` to it's dependency in `Cargo.toml`. There is a `std` feature that enables the...
Oh I see, I will try to make a PR for them. As far as I can tell they only use `alloc` for `Bytes` and `BytesMut` not the `Buf` and...
Will do. My only concerns with `MessageMeta` are 1. Does it generate less code? I think so. 2. Is it any slower to compile? Compile times are already pretty bad....
I thing this is better than what we have now, however it doesn't really solve the issues of how to get message metadata from the message id or name. In...
I don't understand how this can increase memory usage in comparison to the current API. Currently code needs to be generated for the `Default` impls anyway. All this metadata is...
I got interested and ran some tests. I used the embedded example provided by this crate in order to get some binary size measurements. Note that in the example no...
Yes, it can be made constant. In fact, the entire `MessageMeta` could be constant and all of that would get inlined at compile time. So I think it is very...
Oh, interesting... But I guess this example isn't large enough to represent a real usecase. In particular, pretty much all message ids are in range `0..256` because of MAVLink V1...
Great, so can we agree that this optimization is indeed better overall? Since although without `--cfg discriminant`, `fn message_id(&self)` is still fast, that's not the point of the optimization, the...
Well, yes. But that's only if you actually use `match msg { ... al variants ... }` and, if you're doing that you'll have to pay for it. The optimization...