#[repr(C)]pub struct CSmlError {
pub code: c_int,
pub line: c_int,
pub column: c_int,
pub position: usize,
pub source: [c_char; 128],
pub text: [c_char; 256],
}Expand description
与 sml_rs.h 的 sml_error 一一对应。
字段顺序、类型、数组长度必须与头文件完全一致,否则跨语言内存布局错位。
Fields§
§code: c_int§line: c_int§column: c_int§position: usize§source: [c_char; 128]§text: [c_char; 256]Auto Trait Implementations§
impl Freeze for CSmlError
impl RefUnwindSafe for CSmlError
impl Send for CSmlError
impl Sync for CSmlError
impl Unpin for CSmlError
impl UnsafeUnpin for CSmlError
impl UnwindSafe for CSmlError
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