#[non_exhaustive]pub enum TypesetError {
Tex {
message: String,
line: Option<u32>,
span: Option<ByteSpan>,
},
Sandbox {
message: String,
span: Option<ByteSpan>,
},
Budget,
NodeLimit {
limit: usize,
},
Font {
spec: String,
error: FontError,
},
Format {
message: String,
},
TooLong,
NoOutput,
Lowering {
message: String,
},
}Expand description
Why a fragment could not be typeset.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Tex
TeX reported an error, which ends the run.
Fields
Sandbox
The sandbox rejected a command, such as a math shift that leaves the math or a file access.
Fields
Budget
The fragment ran past Options::op_budget, it is too complex or does not terminate.
NodeLimit
The fragment lowers to more than Options::max_nodes IR nodes.
Font
A font the format needs could not be loaded.
Format
The format’s state cannot run fragments.
TooLong
The fragment is longer than a span can index.
NoOutput
The run finished without building the fragment’s box.
Lowering
The laid out fragment broke an IR invariant, a bug in the lowering.
Trait Implementations§
Source§impl Clone for TypesetError
impl Clone for TypesetError
Source§impl Debug for TypesetError
impl Debug for TypesetError
Source§impl Display for TypesetError
impl Display for TypesetError
impl Eq for TypesetError
Source§impl Error for TypesetError
impl Error for TypesetError
1.30.0 · 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()
Source§impl PartialEq for TypesetError
impl PartialEq for TypesetError
impl StructuralPartialEq for TypesetError
Auto Trait Implementations§
impl Freeze for TypesetError
impl RefUnwindSafe for TypesetError
impl Send for TypesetError
impl Sync for TypesetError
impl Unpin for TypesetError
impl UnsafeUnpin for TypesetError
impl UnwindSafe for TypesetError
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