Remove ErrorKind::Ok
This commit is contained in:
@@ -35,10 +35,6 @@ use std::fmt;
|
|||||||
/// Kinds of errors
|
/// Kinds of errors
|
||||||
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
||||||
pub enum ErrorKind {
|
pub enum ErrorKind {
|
||||||
/// OK
|
|
||||||
// TODO(tarcieri): replace this with proper result types
|
|
||||||
Ok,
|
|
||||||
|
|
||||||
/// Memory error
|
/// Memory error
|
||||||
MemoryError,
|
MemoryError,
|
||||||
|
|
||||||
@@ -95,7 +91,6 @@ impl ErrorKind {
|
|||||||
/// assist in web searches for relevant information for these errors.
|
/// assist in web searches for relevant information for these errors.
|
||||||
pub fn name(self) -> &'static str {
|
pub fn name(self) -> &'static str {
|
||||||
match self {
|
match self {
|
||||||
ErrorKind::Ok => "YKPIV_OK",
|
|
||||||
ErrorKind::MemoryError => "YKPIV_MEMORY_ERROR",
|
ErrorKind::MemoryError => "YKPIV_MEMORY_ERROR",
|
||||||
ErrorKind::PcscError => "YKPIV_PCSC_ERROR",
|
ErrorKind::PcscError => "YKPIV_PCSC_ERROR",
|
||||||
ErrorKind::SizeError => "YKPIV_SIZE_ERROR",
|
ErrorKind::SizeError => "YKPIV_SIZE_ERROR",
|
||||||
@@ -118,7 +113,6 @@ impl ErrorKind {
|
|||||||
/// Error message
|
/// Error message
|
||||||
pub fn msg(self) -> &'static str {
|
pub fn msg(self) -> &'static str {
|
||||||
match self {
|
match self {
|
||||||
ErrorKind::Ok => "OK",
|
|
||||||
ErrorKind::MemoryError => "memory error",
|
ErrorKind::MemoryError => "memory error",
|
||||||
ErrorKind::PcscError => "PCSC error",
|
ErrorKind::PcscError => "PCSC error",
|
||||||
ErrorKind::SizeError => "size error",
|
ErrorKind::SizeError => "size error",
|
||||||
|
|||||||
Reference in New Issue
Block a user