@@ -28,24 +28,32 @@ impl DecisionCommand {
28
28
let mut toks = input. clone ( ) ;
29
29
30
30
match toks. peek_token ( ) ? {
31
- Some ( Token :: Word ( "merge" ) ) => {
32
- command_or_error ( input, & mut toks, Self {
31
+ Some ( Token :: Word ( "merge" ) ) => command_or_error (
32
+ input,
33
+ & mut toks,
34
+ Self {
33
35
resolution : Resolution :: Merge ,
34
36
reversibility : Reversibility :: Reversible ,
35
- } )
36
- }
37
- Some ( Token :: Word ( "hold" ) ) => {
38
- command_or_error ( input, & mut toks, Self {
37
+ } ,
38
+ ) ,
39
+ Some ( Token :: Word ( "hold" ) ) => command_or_error (
40
+ input,
41
+ & mut toks,
42
+ Self {
39
43
resolution : Resolution :: Hold ,
40
44
reversibility : Reversibility :: Reversible ,
41
- } )
42
- }
45
+ } ,
46
+ ) ,
43
47
_ => Ok ( None ) ,
44
48
}
45
49
}
46
50
}
47
51
48
- fn command_or_error < ' a > ( input : & mut Tokenizer < ' a > , toks : & mut Tokenizer < ' a > , command : DecisionCommand ) -> Result < Option < DecisionCommand > , Error < ' a > > {
52
+ fn command_or_error < ' a > (
53
+ input : & mut Tokenizer < ' a > ,
54
+ toks : & mut Tokenizer < ' a > ,
55
+ command : DecisionCommand ,
56
+ ) -> Result < Option < DecisionCommand > , Error < ' a > > {
49
57
toks. next_token ( ) ?;
50
58
if let Some ( Token :: Dot ) | Some ( Token :: EndOfLine ) = toks. peek_token ( ) ? {
51
59
* input = toks. clone ( ) ;
@@ -70,7 +78,7 @@ impl fmt::Display for ParseError {
70
78
}
71
79
}
72
80
73
- #[ derive( Serialize , Deserialize , Debug , Clone , ToSql , FromSql , Eq , PartialEq ) ]
81
+ #[ derive( Serialize , Deserialize , Debug , Clone , Copy , ToSql , FromSql , Eq , PartialEq ) ]
74
82
#[ postgres( name = "reversibility" ) ]
75
83
pub enum Reversibility {
76
84
#[ postgres( name = "reversible" ) ]
0 commit comments