-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
First preparations for release 0.4.0 #8
Conversation
fd9cadf
to
067b75c
Compare
bbb2caa
to
83f1cb7
Compare
Can you explain your plans for the |
That way we don't have to do this now, if we want in the feature we can add a default-enabled But if before that we realize that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would introduce the heapless-0.8
feature directly because it would make it explicit which crates actually use the conversions. (I suspect it will only be one or two.) And I don’t think it makes a difference for a potential update to heapless
0.9. Best case we can just add a feature for it, or we need a breaking release anyway where we can also change the features. But it’s not a big issue so I’m also fine with the default
approach.
I prefer the |
Just one final observation from my side: If we use the |
That's a good point. I'll move to directly have the |
cbor
featureDeref
impl toheapless
and replace it with a impl ofDeref<Target = [u8]>
try_from(f: impl FnOnce(&mut [u8]) -> Result<usize, ()>
APIAFAIK this is only used in
trussed-utils
to serializecbor
, which can be done through dedicatedcbor-smol
methods instead.insert_slice_at
This is only used in
fido-authenticator
to add data to the beginning of the buffer. This can easily be made in 3 lines of code without using internal APIs.From<Bytes<N>> for Vec<u8, N>
and vice-versadefault
features required (so that we can feature-flag theheapless
parts of the public API in the future).resize_default
toresize_zero
since we know thatDefault
meansZero
here.