@@ -34,11 +34,19 @@ pub struct Options {
34
34
/// A list of directories to consider temporary, in addition to those
35
35
/// specified by `hardcoded-tmp-directory`.
36
36
pub hardcoded_tmp_directory_extend : Option < Vec < String > > ,
37
+ #[ option(
38
+ default = "false" ,
39
+ value_type = "bool" ,
40
+ example = "check-typed-exception = true"
41
+ ) ]
42
+ /// A list of directories to consider temporary.
43
+ pub check_typed_exception : Option < bool > ,
37
44
}
38
45
39
46
#[ derive( Debug , Hash ) ]
40
47
pub struct Settings {
41
48
pub hardcoded_tmp_directory : Vec < String > ,
49
+ pub check_typed_exception : bool ,
42
50
}
43
51
44
52
impl From < Options > for Settings {
@@ -55,6 +63,7 @@ impl From<Options> for Settings {
55
63
. into_iter ( ) ,
56
64
)
57
65
. collect ( ) ,
66
+ check_typed_exception : options. check_typed_exception . unwrap_or ( false ) ,
58
67
}
59
68
}
60
69
}
@@ -64,6 +73,7 @@ impl From<Settings> for Options {
64
73
Self {
65
74
hardcoded_tmp_directory : Some ( settings. hardcoded_tmp_directory ) ,
66
75
hardcoded_tmp_directory_extend : None ,
76
+ check_typed_exception : Some ( settings. check_typed_exception ) ,
67
77
}
68
78
}
69
79
}
@@ -72,6 +82,7 @@ impl Default for Settings {
72
82
fn default ( ) -> Self {
73
83
Self {
74
84
hardcoded_tmp_directory : default_tmp_dirs ( ) ,
85
+ check_typed_exception : false ,
75
86
}
76
87
}
77
88
}
0 commit comments