-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Upgrade percent-encoding
to 2.x and base64
to 0.12.
#1349
Conversation
I understand employing loops in the |
Since we are working towards compiling on stable (and nearly there!), I would reject a PR that fundamentally and unconditionally requires new
I agree using cc #998. |
@jebrosen, thanks for your thoughts! The |
Oh, that's awkward timing - it will hit stable in Here's the hypothetical macro I mentioned earlier and some example usage; the actual sets are untested. This could be useful as a starting point for any approach: use percent_encoding::AsciiSet;
macro_rules! ascii_set {
($e:expr;) => { $e };
($e:expr; - $sub:literal $($rest:tt)*) => { ascii_set!($e.remove($sub); $($rest)*) };
($e:expr; + $add:literal $($rest:tt)*) => { ascii_set!($e.add($add); $($rest)*) };
}
const PCHAR_SET: AsciiSet = ascii_set!(
percent_encoding::NON_ALPHANUMERIC;
-b'!' -b'$' -b'&' -b'\''
-b'(' -b')' -b'*' -b'+' -b',' -b'-' -b'.' -b'/'
-b':' -b';'
-b'=' -b'@'
-b'_'
-b'~'
);
const QUERY_SET: AsciiSet = ascii_set!(PCHAR_SET;
-b'?'
+b'%'
+b'+'
); |
@jakubadamw unless you have some unpushed work on this, I'm planning to rebase this onto |
@jebrosen, I don't. Sure, sounds great, thanks! 🙂 |
No description provided.