Setup of update and render loop for CUI
This commit is contained in:
@@ -114,6 +114,12 @@ impl std::convert::From<std::convert::Infallible> for Error {
|
||||
}
|
||||
}
|
||||
|
||||
impl std::convert::From<std::sync::mpsc::RecvError> for Error {
|
||||
fn from(error: std::sync::mpsc::RecvError) -> Self {
|
||||
Error::from_error(error)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn exit_with_error(error: Error) {
|
||||
error.print_to_std_err();
|
||||
std::process::exit(error.exit_code);
|
||||
|
Reference in New Issue
Block a user