fix(types/error): Add a pseudo error for infallible conversions
This commit is contained in:
parent
0ebbc4346e
commit
9e37456f74
|
@ -19,7 +19,7 @@
|
||||||
* If not, see <https://www.gnu.org/licenses/>.
|
* If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
use std::ffi::c_char;
|
use std::{convert::Infallible, ffi::c_char};
|
||||||
|
|
||||||
use thiserror::Error;
|
use thiserror::Error;
|
||||||
|
|
||||||
|
@ -43,6 +43,6 @@ pub enum TypeConversionError {
|
||||||
#[error("The returned Result was an error: {original_message}")]
|
#[error("The returned Result was an error: {original_message}")]
|
||||||
ResultWasErr { original_message: String },
|
ResultWasErr { original_message: String },
|
||||||
|
|
||||||
#[error("This funciton is not admissable")]
|
#[error("This conversion was infallible, and will thus never fail")]
|
||||||
NotAdmissable,
|
Infallible(#[from] Infallible),
|
||||||
}
|
}
|
||||||
|
|
Reference in New Issue