This needs a bit more thought. To support outside-in error writing, converters need access to an allocator so they can create new buffer writers. This can be done by passing in a pointer to an ArrayList object directly, rather than an already bound writer.
18 lines
359 B
Zig
18 lines
359 B
Zig
pub const ConversionError = error{
|
|
OutOfMemory,
|
|
ConversionFailed,
|
|
};
|
|
|
|
pub const ParseError = error{
|
|
UnexpectedFailure,
|
|
EmptyArgs,
|
|
MissingValue,
|
|
ExtraValue,
|
|
FusedShortTagValueMissing,
|
|
UnknownLongTagParameter,
|
|
UnknownShortTagParameter,
|
|
RequiredParameterMissing,
|
|
};
|
|
|
|
pub const NoclipError = ParseError || ConversionError;
|