Move const def nearer usage.

This commit is contained in:
Giles Cope 2021-02-14 18:23:30 +00:00
parent daa55acdb0
commit 33d8b04568
No known key found for this signature in database
GPG Key ID: DF85161DAE0FF36B

View File

@ -6,9 +6,6 @@ use crate::intrinsics;
use crate::mem;
use crate::str::FromStr;
/// If 6th bit set ascii is upper case.
const ASCII_CASE_MASK: u8 = 0b0010_0000;
// Used because the `?` operator is not allowed in a const context.
macro_rules! try_opt {
($e:expr) => {
@ -155,6 +152,9 @@ impl isize {
usize_isize_to_xe_bytes_doc!(), usize_isize_from_xe_bytes_doc!() }
}
/// If 6th bit set ascii is upper case.
const ASCII_CASE_MASK: u8 = 0b0010_0000;
#[lang = "u8"]
impl u8 {
uint_impl! { u8, u8, 8, 255, 2, "0x82", "0xa", "0x12", "0x12", "0x48", "[0x12]",