pub enum CDecl {
Function {
ret_type: CType,
name: String,
params: Vec<(CType, String)>,
body: Vec<CStmt>,
is_static: bool,
},
Struct {
name: String,
fields: Vec<(CType, String)>,
},
Typedef {
original: CType,
alias: String,
},
Global {
ty: CType,
name: String,
init: Option<CExpr>,
is_static: bool,
},
ForwardDecl {
ret_type: CType,
name: String,
params: Vec<(CType, String)>,
},
}Expand description
A top-level C declaration.
Variants§
Function
Function definition.
Struct
Struct definition.
Typedef
Typedef.
Global
Global variable.
ForwardDecl
Forward declaration (function prototype).
Trait Implementations§
impl StructuralPartialEq for CDecl
Auto Trait Implementations§
impl Freeze for CDecl
impl RefUnwindSafe for CDecl
impl Send for CDecl
impl Sync for CDecl
impl Unpin for CDecl
impl UnsafeUnpin for CDecl
impl UnwindSafe for CDecl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more