mirror of
https://github.com/loot/loot-condition-interpreter.git
synced 2026-07-27 14:16:09 -07:00
Add more derived traits to enums and structs
This commit is contained in:
+3
-3
@@ -86,7 +86,7 @@ impl error::Error for Error {
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, PartialEq, Eq, Clone, Copy)]
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
|
||||
pub enum MoreDataNeeded {
|
||||
/// It's not known how much more data are needed
|
||||
UnknownSize,
|
||||
@@ -94,7 +94,7 @@ pub enum MoreDataNeeded {
|
||||
Size(NonZeroUsize),
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
#[derive(Clone, Debug, Eq, PartialEq)]
|
||||
pub struct ParsingError<I: fmt::Debug + fmt::Display> {
|
||||
input: I,
|
||||
kind: ParsingErrorKind,
|
||||
@@ -143,7 +143,7 @@ impl<I: fmt::Debug + fmt::Display> nom::error::ParseError<I> for ParsingError<I>
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
#[derive(Clone, Debug, Eq, PartialEq)]
|
||||
pub enum ParsingErrorKind {
|
||||
InvalidRegexSyntax(String),
|
||||
InvalidRegexUnknown,
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ pub mod parse;
|
||||
mod path;
|
||||
mod version;
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
|
||||
pub enum ComparisonOperator {
|
||||
Equal,
|
||||
NotEqual,
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ use function::Function;
|
||||
|
||||
type ParsingResult<'a, T> = IResult<&'a str, T, ParsingError<&'a str>>;
|
||||
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
|
||||
#[non_exhaustive]
|
||||
pub enum GameType {
|
||||
Oblivion,
|
||||
|
||||
Reference in New Issue
Block a user