use serde::Serialize;
use crate::CppEvidence;
#[derive(Debug, Clone, PartialEq, Eq, Serialize)]
#[serde(rename_all = "snake_case")]
#[non_exhaustive]
pub enum CppReturnChannel {
Unknown,
GeneralPurpose,
FloatingPoint,
AggregateIndirect,
Void,
}
#[derive(Debug, Clone, Serialize)]
#[serde(rename_all = "snake_case")]
#[non_exhaustive]
pub enum CppBodyKind {
Standard,
Thunk,
Stub,
Unknown,
}
#[derive(Debug, Clone, PartialEq, Eq, Serialize)]
#[serde(tag = "hint", rename_all = "snake_case")]
#[non_exhaustive]
pub enum ArgumentTypeHint {
Unknown,
Scalar,
FloatingPoint,
Pointer,
CString,
ClassPointer {
#[doc = "The class_name field."]
class_name: String,
},
ObjcObject,
StructPointer,
}
#[derive(Debug, Clone, Serialize)]
pub struct CppBodyAnalysis {
pub arch: String,
pub kind: CppBodyKind,
pub return_channel: CppReturnChannel,
pub this_adjustment: Option<i64>,
pub likely_wrapper: bool,
pub param_count: Option<u32>,
pub argument_hints: Vec<ArgumentTypeHint>,
pub evidence: Vec<CppEvidence>,
}