Lines Matching refs:O
170 impl<O: ByteOrder> Debug for $name<O> {
186 impl<O: ByteOrder> Debug for $name<O> {
206 impl<O: ByteOrder> $trait for $name<O> {
240 impl<O: ByteOrder> PartialOrd for $name<O> {
263 impl<O> core::ops::Not for $name<O> {
264 type Output = $name<O>;
267 fn not(self) -> $name<O> {
273 impl<O: ByteOrder> PartialOrd for $name<O> {
280 impl<O: ByteOrder> Ord for $name<O> {
287 impl<O: ByteOrder> PartialOrd<$native> for $name<O> {
295 impl<O: ByteOrder> core::ops::Neg for $name<O> {
296 type Output = $name<O>;
299 fn neg(self) -> $name<O> {
302 $name::<O>::new(-self_native)
314 impl<O: ByteOrder> core::ops::$trait<$name<O>> for $name<O> {
315 type Output = $name<O>;
318 fn $method(self, rhs: $name<O>) -> $name<O> {
322 $name::<O>::new(result_native)
326 impl<O: ByteOrder> core::ops::$trait<$name<O>> for $native {
327 type Output = $name<O>;
330 fn $method(self, rhs: $name<O>) -> $name<O> {
333 $name::<O>::new(result_native)
337 impl<O: ByteOrder> core::ops::$trait<$native> for $name<O> {
338 type Output = $name<O>;
341 fn $method(self, rhs: $native) -> $name<O> {
344 $name::<O>::new(result_native)
348 impl<O: ByteOrder> core::ops::$trait_assign<$name<O>> for $name<O> {
350 fn $method_assign(&mut self, rhs: $name<O>) {
355 impl<O: ByteOrder> core::ops::$trait_assign<$name<O>> for $native {
357 fn $method_assign(&mut self, rhs: $name<O>) {
363 impl<O: ByteOrder> core::ops::$trait_assign<$native> for $name<O> {
377 impl<O: ByteOrder> core::ops::$trait<$name<O>> for $name<O> {
378 type Output = $name<O>;
381 fn $method(self, rhs: $name<O>) -> $name<O> {
389 impl<O: ByteOrder> core::ops::$trait<$name<O>> for $native {
390 type Output = $name<O>;
393 fn $method(self, rhs: $name<O>) -> $name<O> {
397 let slf_byteorder = $name::<O>::new(self);
407 impl<O: ByteOrder> core::ops::$trait<$native> for $name<O> {
408 type Output = $name<O>;
411 fn $method(self, rhs: $native) -> $name<O> {
413 let rhs_byteorder = $name::<O>::new(rhs);
425 impl<O: ByteOrder> core::ops::$trait_assign<$name<O>> for $name<O> {
427 fn $method_assign(&mut self, rhs: $name<O>) {
432 impl<O: ByteOrder> core::ops::$trait_assign<$name<O>> for $native {
434 fn $method_assign(&mut self, rhs: $name<O>) {
442 impl<O: ByteOrder> core::ops::$trait_assign<$native> for $name<O> {
465 pub const MAX_VALUE: $name<O> = $name([0xFFu8; $bytes], PhantomData);
527 pub struct $name<O>([u8; $bytes], PhantomData<O>);
531 impl_known_layout!(O => $name<O>);
540 impl_or_verify!(O => Immutable for $name<O>);
541 impl_or_verify!(O => TryFromBytes for $name<O>);
542 impl_or_verify!(O => FromZeros for $name<O>);
543 impl_or_verify!(O => FromBytes for $name<O>);
544 impl_or_verify!(O => IntoBytes for $name<O>);
545 impl_or_verify!(O => Unaligned for $name<O>);
548 impl<O> Default for $name<O> {
550 fn default() -> $name<O> {
555 impl<O> $name<O> {
561 pub const ZERO: $name<O> = $name([0u8; $bytes], PhantomData);
569 pub const fn from_bytes(bytes: [u8; $bytes]) -> $name<O> {
583 impl<O: ByteOrder> $name<O> {
590 pub const fn new(n: $native) -> $name<O> {
591 let bytes = match O::ORDER {
607 match O::ORDER {
628 impl<O: ByteOrder> From<$name<O>> for [u8; $bytes] {
630 fn from(x: $name<O>) -> [u8; $bytes] {
635 impl<O: ByteOrder> From<[u8; $bytes]> for $name<O> {
637 fn from(bytes: [u8; $bytes]) -> $name<O> {
642 impl<O: ByteOrder> From<$name<O>> for $native {
644 fn from(x: $name<O>) -> $native {
649 impl<O: ByteOrder> From<$native> for $name<O> {
651 fn from(x: $native) -> $name<O> {
657 impl<O: ByteOrder> From<$name<O>> for $larger_native {
659 fn from(x: $name<O>) -> $larger_native {
666 impl<O: ByteOrder> TryFrom<$larger_native_try> for $name<O> {
669 fn try_from(x: $larger_native_try) -> Result<$name<O>, TryFromIntError> {
676 impl<O: ByteOrder, P: ByteOrder> From<$name<O>> for $larger_byteorder<P> {
678 fn from(x: $name<O>) -> $larger_byteorder<P> {
685 impl<O: ByteOrder, P: ByteOrder> TryFrom<$larger_byteorder_try<P>> for $name<O> {
688 fn try_from(x: $larger_byteorder_try<P>) -> Result<$name<O>, TryFromIntError> {
694 impl<O> AsRef<[u8; $bytes]> for $name<O> {
701 impl<O> AsMut<[u8; $bytes]> for $name<O> {
708 impl<O> PartialEq<$name<O>> for [u8; $bytes] {
710 fn eq(&self, other: &$name<O>) -> bool {
715 impl<O> PartialEq<[u8; $bytes]> for $name<O> {
722 impl<O: ByteOrder> PartialEq<$native> for $name<O> {
1154 impl<O: ByteOrder> ByteOrderTypeUnsigned for $name<O> {
1155 const MAX_VALUE: $name<O> = $name::MAX_VALUE;
1178 impl<O: ByteOrder> ByteOrderType for $name<O> {
1182 const ZERO: $name<O> = $name::ZERO;
1184 fn new(native: $native) -> $name<O> {
1196 fn from_bytes(bytes: [u8; mem::size_of::<$native>()]) -> $name<O> {