1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#![no_std]
#![feature(more_qualified_paths)]

use macro_bits::serializable_enum;

serializable_enum! {
    #[derive(Clone, Copy, Debug, Default, PartialEq, Eq)]
    /// The EtherType as described in IEEE 802.3
    pub enum EtherType: u16 {
        #[default]
        IPv4 => 0x0800,
        ARP => 0x0806,
        WoLAN => 0x0842,
        IPv6 => 0x86DD
    }
}