Crates.io | errorser |
lib.rs | errorser |
version | 1.0.1 |
source | src |
created_at | 2016-02-07 18:27:49.4725 |
updated_at | 2016-02-07 18:27:49.4725 |
description | Serializes and psudo-deserializes structs implementing the Error trait. |
homepage | |
repository | https://github.com/Ameliorate/errorser |
max_upload_size | |
id | 4119 |
size | 11,120 |
Simple hack to serialize &Error values in rust, using either serde or rustc-serialize.
Note that due to the way errors are serialized, some custom ones with side effects and the like are improperly serialized, instead giving the descriptions and causes that were true at the time of serialization, instead of what is currently true. This is fine for most uses, but may cause unexpected behavior when serializing the more obscure errors.
#Links
TODO: Actually link to these things when they exist.
Documentation
Crates.io
#Examples
use errorser::{deserialize_error_string, serialize_error_string};
let error = error_prone_function();
let string = serialize_error_string(&error);
let pseudoerror = deserialize_error_string(&string).unwrap();