fn apply_ip_mask_bytes(ip: &mut [u8], mask: &[u8], invert: bool, set: bool) {
    debug_assert!(ip.len() == mask.len());
    for (b, m) in ip.iter_mut().zip(mask.iter()) {
        let m: u8 = match invert {
            false => *m,
            true => !*m,
        };

        if set {
            *b |= m;
        } else {
            *b &= m;
        }
    }
}
/// Apply the given mask to the given IP address bytes. See IpNet::apply_mask
/// for details on behavior.
Apply the given mask to the given IP address bytes.
Apply the given mask to the given IP address bytes .
fn apply_ip_mask_bytes(ip: &mut [u8], mask: &[u8], invert: bool, set: bool) {
    debug_assert!(ip.len() == mask.len());
    for (b, m) in ip.iter_mut().zip(mask.iter()) {
        let m: u8 = match invert {
            false => *m,
            true => !*m,
        };
        if set {
            *b |= m;
        } else {
            *b &= m;
        }
    }
}
fn apply_ip_mask_bytes ( ip : & mut [ u8 ] , mask : & [ u8 ] , invert : bool , set : bool ) { debug_assert ! ( ip len ( ) mask len ( ) ) ; for ( b , m ) in ip . iter_mut ( ) . zip ( mask . iter ( ) ) { let m : u8 = match invert { false => * m , true => ! * m , } ; if set { * b |= m ; } else { * b &= m ; } } }
Apply the given mask to the given IP address bytes.
Apply the given mask to the given IP address bytes .
ip
&mut [u8]
mask
&[u8]
invert
bool
set
bool
ip
&mut [u8]
mask
&[u8]
invert
bool
set
bool