We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ffc6589 commit a6cba65Copy full SHA for a6cba65
src/main.rs
@@ -21,7 +21,6 @@ fn ip6_reverse(ip: &Ipv6Addr) -> String {
21
let mut rev = String::with_capacity(64);
22
for oct in ip.octets().iter().rev() {
23
rev.push_str(format!("{:x}.", oct & 0x0fu8).as_str());
24
- // Rust gets mad about right-shifting set bits, so we need to mask + shift
25
rev.push_str(format!("{:x}.", (oct & 0xf0u8) >> 4u8).as_str());
26
}
27
rev
0 commit comments