pub enum DagError {
InvalidInput(String),
BudgetExceeded {
label: String,
limit: u64,
},
InvalidResult(String),
Overflow(String),
Io {
path: PathBuf,
source: Error,
},
DgcFormat(String),
ObjParse {
line: usize,
reason: String,
},
}Expand description
编译管线错误。Display 输出即面向用户的诊断信息,不依赖上下文补充。
Variants§
InvalidInput(String)
输入几何非法(TS: invalid-input)。
BudgetExceeded
超出构建预算(TS: budget-exceeded)。
InvalidResult(String)
内部结果非法或不可表示(TS: invalid-result / overflow)。
Overflow(String)
数值溢出:输出尺寸无法在目标宽度内表示。
Io
I/O 失败(文件读写)。
DgcFormat(String)
.dgc 文件结构非法(魔数/版本/截断/校验和不符)。
ObjParse
OBJ 解析失败(行号 + 原因)。
Trait Implementations§
Source§impl Error for DagError
impl Error for DagError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for DagError
impl !UnwindSafe for DagError
impl Freeze for DagError
impl Send for DagError
impl Sync for DagError
impl Unpin for DagError
impl UnsafeUnpin for DagError
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