1#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)]
3pub enum InvalidArrFnRepr {
4 #[allow(missing_docs)]
6 InvalidValue {
7 input: usize,
8 value: usize,
9 max: usize,
10 },
11 #[allow(missing_docs)]
13 RepeatedValue {
14 first_input: usize,
15 second_input: usize,
16 value: usize,
17 },
18}
19
20#[derive(Debug, Copy, Clone, Ord, PartialOrd, Eq, PartialEq, Hash)]
21pub struct CycleElementLocation {
23 pub cycle_index: usize,
25 pub index: usize,
27}
28
29#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)]
31pub enum InvalidCycleRepr {
32 #[allow(missing_docs)]
34 InvalidValue {
35 location: CycleElementLocation,
36 value: usize,
37 max: usize,
38 },
39 #[allow(missing_docs)]
41 RepeatedValue {
42 first_occurrence: CycleElementLocation,
43 second_occurrence: CycleElementLocation,
44 value: usize,
45 },
46}
47
48#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)]
50pub enum InvalidSwapRepr {
51 #[allow(missing_docs)]
53 InvalidLeftValue {
54 index: usize,
55 value: usize,
56 max: usize,
57 },
58 #[allow(missing_docs)]
60 InvalidRightValue {
61 index: usize,
62 value: usize,
63 max: usize,
64 },
65}
66
67#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)]
69#[allow(missing_docs)]
70pub struct TooLongSliceForPermutation {
71 pub length: usize,
72 pub max: usize,
73}