tensor_escrow/generated/errors/
tensor_escrow.rs

1//! This code was AUTOGENERATED using the kinobi library.
2//! Please DO NOT EDIT THIS FILE, instead use visitors
3//! to add features, then rerun kinobi to update it.
4//!
5//! <https://github.com/kinobi-so/kinobi>
6//!
7
8use num_derive::FromPrimitive;
9use thiserror::Error;
10
11#[derive(Clone, Debug, Eq, Error, FromPrimitive, PartialEq)]
12pub enum TensorEscrowError {
13    /// 6016 - bad owner
14    #[error("bad owner")]
15    BadOwner = 0x1780,
16    /// 6027 - bad margin account passed
17    #[error("bad margin account passed")]
18    BadMargin = 0x178B,
19    /// 6032 - margin account has pools open and is in use
20    #[error("margin account has pools open and is in use")]
21    MarginInUse = 0x1790,
22}
23
24impl solana_program::program_error::PrintProgramError for TensorEscrowError {
25    fn print<E>(&self) {
26        solana_program::msg!(&self.to_string());
27    }
28}