File tree 3 files changed +21
-10
lines changed
3 files changed +21
-10
lines changed Original file line number Diff line number Diff line change @@ -159,16 +159,14 @@ fn find_botan_include_dir() -> std::path::PathBuf {
159
159
for major in [ 3 , 2 ] {
160
160
let lib_name = format ! ( "botan-{}" , major) ;
161
161
162
- let statik = if cfg ! ( feature = "static" ) {
163
- true
164
- } else {
165
- false
166
- } ;
162
+ let statik = cfg ! ( feature = "static" ) ;
167
163
168
164
if let Ok ( config) = pkg_config:: Config :: new ( ) . statik ( statik) . probe ( & lib_name) {
169
165
return config. include_paths [ 0 ] . clone ( ) ;
170
166
}
171
167
}
168
+
169
+ panic ! ( "Unable to find the headers corresponding with any supported version of Botan" ) ;
172
170
}
173
171
174
172
#[ cfg( not( feature = "pkg-config" ) ) ]
@@ -206,7 +204,7 @@ fn find_botan_include_dir() -> std::path::PathBuf {
206
204
}
207
205
}
208
206
209
- panic ! ( "Unable to find the headers cooresponding with any supported version of Botan" ) ;
207
+ panic ! ( "Unable to find the headers corresponding with any supported version of Botan" ) ;
210
208
}
211
209
}
212
210
Original file line number Diff line number Diff line change @@ -25,4 +25,8 @@ default = ["std"]
25
25
std = []
26
26
vendored = [" botan-sys/vendored" ]
27
27
static = [" botan-sys/static" ]
28
- pkg-config = [" botan-sys/pkg-config" ]
28
+ pkg-config = [" botan-sys/pkg-config" ]
29
+
30
+ [lints .clippy ]
31
+ # introduced because of from_str
32
+ should_implement_trait = " allow"
Original file line number Diff line number Diff line change @@ -52,8 +52,11 @@ impl RandomNumberGenerator {
52
52
53
53
/// Create a new reference to the ESDM PRNG (fully seeded)
54
54
///
55
+ /// Availability of this RNG depends on botan being compiled
56
+ /// with ESDM support.
57
+ ///
55
58
/// # Examples
56
- /// ```
59
+ /// ```ignore
57
60
/// let esdm_rng = botan::RandomNumberGenerator::new_esdm().unwrap();
58
61
/// ```
59
62
pub fn new_esdm ( ) -> Result < RandomNumberGenerator > {
@@ -62,8 +65,11 @@ impl RandomNumberGenerator {
62
65
63
66
/// Create a new reference to the ESDM PRNG (with prediction resistance)
64
67
///
68
+ /// Availability of this RNG depends on botan being compiled
69
+ /// with ESDM support.
70
+ ///
65
71
/// # Examples
66
- /// ```
72
+ /// ```ignore
67
73
/// let esdm_rng = botan::RandomNumberGenerator::new_esdm_pr().unwrap();
68
74
/// ```
69
75
pub fn new_esdm_pr ( ) -> Result < RandomNumberGenerator > {
@@ -72,8 +78,11 @@ impl RandomNumberGenerator {
72
78
73
79
/// Create a new reference to the Jitter RNG
74
80
///
81
+ /// Availability of this RNG depends on botan being compiled
82
+ /// with Jitter RNG support.
83
+ ///
75
84
/// # Examples
76
- /// ```
85
+ /// ```ignore
77
86
/// let jitter_rng = botan::RandomNumberGenerator::new_jitter().unwrap();
78
87
/// ```
79
88
pub fn new_jitter ( ) -> Result < RandomNumberGenerator > {
You can’t perform that action at this time.
0 commit comments