#![allow(dead_code, deprecated, unused_variables, unused_mut)] #![feature(ip)] use std::net::{Ipv6Addr, Ipv6MulticastScope}; fn main() { assert_eq!( Ipv6Addr::new(0xff0e, 0, 0, 0, 0, 0, 0, 0).multicast_scope(), Some(Ipv6MulticastScope::Global) ); assert_eq!( Ipv6Addr::new(0, 0, 0, 0, 0, 0xffff, 0xc00a, 0x2ff).multicast_scope(), None ); }