use std::num::ParseIntError;
use thiserror::Error;
use crate::helper::macros::unreachable_err_impl;
#[derive(Debug, Error)]
#[non_exhaustive]
pub enum ParseError {
#[error(transparent)]
ParseIntError(#[from] ParseIntError),
#[error("Invalid colon set, expected format of `key: value`")]
InvalidColonSet,
#[error("The key doesn't exist in `Editor`")]
InvalidKey,
#[error("Invalid comma list, expected format of `key: value, value, value, ...`")]
InvalidCommaList,
#[error("Duplicate field in `Editor`")]
DuplicateField,
}
unreachable_err_impl!(ParseError);