|  | // WARNING: This file is machine generated by fidlgen. | 
|  |  | 
|  | #![allow( | 
|  | deprecated, // FIDL Impl struct pattern is referenced internally | 
|  | unused_parens, // one-element-tuple-case is not a tuple | 
|  | unused_mut, // not all args require mutation, but many do | 
|  | nonstandard_style, // auto-caps does its best, but is not always successful | 
|  | )] | 
|  | #![recursion_limit = "512"] | 
|  |  | 
|  | #[cfg(target_os = "fuchsia")] | 
|  | #[allow(unused_imports)] | 
|  | use fuchsia_zircon as zx; | 
|  |  | 
|  | #[allow(unused_imports)] | 
|  | use { | 
|  | bitflags::bitflags, | 
|  | fidl::{ | 
|  | fidl_bits, fidl_empty_struct, fidl_enum, fidl_struct, fidl_struct_copy, fidl_table, | 
|  | fidl_xunion, | 
|  | }, | 
|  | fuchsia_zircon_status as zx_status, | 
|  | }; | 
|  |  | 
|  | #[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)] | 
|  | #[repr(u32)] | 
|  | pub enum MyStrictEnum { | 
|  | Foo = 1, | 
|  | Bar = 2, | 
|  | } | 
|  |  | 
|  | fidl_enum! { | 
|  | name: MyStrictEnum, | 
|  | prim_ty: u32, | 
|  | members: [ | 
|  | Foo { value: 1, }, | 
|  | Bar { value: 2, }, | 
|  | ], | 
|  | } | 
|  |  | 
|  | #[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)] | 
|  | #[repr(u32)] | 
|  | pub enum MyFlexibleEnum { | 
|  | Foo = 1, | 
|  | Bar = 2, | 
|  | } | 
|  |  | 
|  | fidl_enum! { | 
|  | name: MyFlexibleEnum, | 
|  | prim_ty: u32, | 
|  | members: [ | 
|  | Foo { value: 1, }, | 
|  | Bar { value: 2, }, | 
|  | ], | 
|  | } | 
|  |  | 
|  | #[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)] | 
|  | #[repr(u32)] | 
|  | pub enum MyFlexibleEnumWithCustomUnknown { | 
|  | Foo = 1, | 
|  | Bar = 2, | 
|  | CustomUnknown = 3, | 
|  | } | 
|  |  | 
|  | fidl_enum! { | 
|  | name: MyFlexibleEnumWithCustomUnknown, | 
|  | prim_ty: u32, | 
|  | members: [ | 
|  | Foo { value: 1, }, | 
|  | Bar { value: 2, }, | 
|  | CustomUnknown { value: 3, }, | 
|  | ], | 
|  | } |