lexicon_api/error.rs
1use std::io;
2
3/// Errors that can occur during API extraction and diffing.
4#[derive(Debug, thiserror::Error)]
5pub enum ApiError {
6 #[error("I/O error: {0}")]
7 Io(#[from] io::Error),
8
9 #[error("parse error: {0}")]
10 Parse(#[from] syn::Error),
11
12 #[error("serialization error: {0}")]
13 Serialize(#[from] serde_json::Error),
14
15 #[error("baseline not found: {0}")]
16 BaselineNotFound(String),
17}