|
|
@ -14,6 +14,7 @@ |
|
|
|
//
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
|
|
use std::collections::BTreeMap; |
|
|
|
use std::collections::BTreeMap; |
|
|
|
|
|
|
|
use std::error; |
|
|
|
use std::ffi::CString; |
|
|
|
use std::ffi::CString; |
|
|
|
use std::fmt; |
|
|
|
use std::fmt; |
|
|
|
use std::fs; |
|
|
|
use std::fs; |
|
|
@ -117,6 +118,16 @@ impl From<Error> for String { |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
impl error::Error for Error { |
|
|
|
|
|
|
|
fn description(&self) -> &str { |
|
|
|
|
|
|
|
&self.message |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
fn cause(&self) -> Option<&error::Error> { |
|
|
|
|
|
|
|
None |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
impl fmt::Display for Error { |
|
|
|
impl fmt::Display for Error { |
|
|
|
fn fmt(&self, formatter: &mut fmt::Formatter) -> Result<(), fmt::Error> { |
|
|
|
fn fmt(&self, formatter: &mut fmt::Formatter) -> Result<(), fmt::Error> { |
|
|
|
self.message.fmt(formatter) |
|
|
|
self.message.fmt(formatter) |
|
|
|