Skip to content

Commit

Permalink
Remove pub access to contains method
Browse files Browse the repository at this point in the history
  • Loading branch information
DoumanAsh authored Jul 24, 2019
1 parent 6b5091f commit ed7b991
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion percent_encoding/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const BITS_PER_CHUNK: usize = 8 * std::mem::size_of::<Chunk>();
impl AsciiSet {
/// Called with UTF-8 bytes rather than code points.
/// Not used for non-ASCII bytes.
pub const fn contains(&self, byte: u8) -> bool {
const fn contains(&self, byte: u8) -> bool {
let chunk = self.mask[byte as usize / BITS_PER_CHUNK];
let mask = 1 << (byte as usize % BITS_PER_CHUNK);
(chunk & mask) != 0
Expand Down

0 comments on commit ed7b991

Please sign in to comment.