File tree 1 file changed +4
-12
lines changed
1 file changed +4
-12
lines changed Original file line number Diff line number Diff line change @@ -15,27 +15,19 @@ pub enum Error {
15
15
16
16
impl fmt:: Display for Error {
17
17
fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result {
18
- write ! ( f, "{}" , error:: Error :: description( self ) )
19
- }
20
- }
21
-
22
- impl error:: Error for Error {
23
- fn cause ( & self ) -> Option < & dyn error:: Error > {
24
- None
25
- }
26
-
27
- fn description ( & self ) -> & ' static str {
28
- match * self {
18
+ f. write_str ( match * self {
29
19
Error :: NoLayoutForOpaqueBlob => {
30
20
"Tried to generate an opaque blob, but had no layout"
31
21
}
32
22
Error :: InstantiationOfOpaqueType => {
33
23
"Instantiation of opaque template type or partial template \
34
24
specialization"
35
25
}
36
- }
26
+ } )
37
27
}
38
28
}
39
29
30
+ impl error:: Error for Error { }
31
+
40
32
/// A `Result` of `T` or an error of `bindgen::codegen::error::Error`.
41
33
pub type Result < T > = :: std:: result:: Result < T , Error > ;
You can’t perform that action at this time.
0 commit comments