Skip to content

Commit

Permalink
fixed test
Browse files Browse the repository at this point in the history
  • Loading branch information
Odilf committed Aug 10, 2023
1 parent 0a3c98c commit ee1ae39
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions barbarosa/src/cube_n/parser/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use crate::generic::parse::{FromPest, IntoParseErr, Parsable, ParseError};
type Result<T> = std::result::Result<T, ParseError<Rule>>;

use super::{
moves::{rotation::AxisRotation, Amount, ExtendedAxisMove},
moves::{rotation::AxisRotation, Amount, ExtendedAxisMove, wide::WideMoveCreationError},
space::{Axis, Direction, Face},
AxisMove, WideAxisMove,
};
Expand Down Expand Up @@ -120,7 +120,7 @@ impl<const N: u32> FromPest for WideAxisMove<N> {
};

if depth > N {
panic!("Depth {} is greater than N {}", depth, N);
return Err(ParseError::uknown(WideMoveCreationError::ExcededDepth(depth, N)));
}

let amount = Amount::from_pest(inner.next().into_err()?)?;
Expand Down

0 comments on commit ee1ae39

Please sign in to comment.