-
-
Notifications
You must be signed in to change notification settings - Fork 58
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
Someday: implement ByteSlice
for [u8; N]
using const generics
#86
Labels
enhancement
New feature or request
Comments
Oooooo yes, this would be lovely. I freaking hate This will likely motivate to bump the MSRV sooner than I would otherwise. I'll wait until it's at least been on stable for two release though. |
Would now be a good time for this? |
Closed
This is unblocked now that bstr 1.0 is out and MSRV is 1.60 |
lopopolo
added a commit
to lopopolo/bstr
that referenced
this issue
Sep 14, 2022
PR for this is here: that was pretty painless! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the distant future, when
bstr
can use const generics, the following reduces the amount ofB(b"blah")
you need to to literals do by a decent amount, letting you useByteSlice
methods directly onb"foo"
.(Of course, you still need
B
for the&str
literal case, e.g.B("😅")
and such, but in practice that case isn't as bad, sinceas_bytes()
also works)(Well, in practice you also need
impl<const N: usize> Sealed for [u8; N] {}
, but that's not important).Nothing to do for now, but would be a nice thing to add when (or if, I guess) the MSRV gets to 1.51.
The text was updated successfully, but these errors were encountered: