Do not impl Debug but derive

This commit is contained in:
Matthias Beyer 2016-01-16 14:26:29 +01:00
parent 0ace28897f
commit f36615940a

View file

@ -8,7 +8,7 @@ use std::convert::From;
use std::io::Error as IOError;
#[derive(Clone, Copy)]
#[derive(Clone, Copy, Debug)]
pub enum StoreErrorKind {
IdNotFound,
OutOfMemory,
@ -22,15 +22,6 @@ fn store_error_type_as_str(e: &StoreErrorKind) -> &'static str {
}
}
impl Debug for StoreErrorKind {
fn fmt(&self, fmt: &mut Formatter) -> Result<(), FmtError> {
try!(write!(fmt, "{:?}", store_error_type_as_str(self)));
Ok(())
}
}
impl Display for StoreErrorKind {
fn fmt(&self, fmt: &mut Formatter) -> Result<(), FmtError> {