use quick_xml; error_chain! { foreign_links { Io(::std::io::Error); XML(quick_xml::errors::Error); NumParse(::std::num::ParseIntError); Utf8(::std::str::Utf8Error); } errors { FromXml(pos: usize, tag: String) { description("invalid input while processing tag") display("error at pos {}: invalid <{}>", pos, tag) } ElementText(pos: usize) { description("found something other than text") display("error at pos {}: not text", pos) } ClosingTag(pos: usize) { description("found something other than a closing tag") display("error at pos {}: expected a closing tag", pos) } EOF { description("premature EOF") display("expected more things") } } }