instruction.rs 514 B

12345678910111213141516171819
  1. use crate::state::AddressInfoData;
  2. use steel::*;
  3. /// Instruction types for the address info program
  4. #[repr(u8)]
  5. #[derive(Clone, Copy, Debug, Eq, PartialEq, TryFromPrimitive)]
  6. pub enum AddressInfoInstruction {
  7. CreateAddressInfo = 0,
  8. }
  9. /// Instruction data for creating address info
  10. #[repr(C)]
  11. #[derive(Clone, Copy, Debug, Pod, Zeroable)]
  12. pub struct CreateAddressInfo {
  13. pub data: AddressInfoData,
  14. }
  15. // Link instruction type with its data structure
  16. instruction!(AddressInfoInstruction, CreateAddressInfo);