use thiserror::Error;
#[derive(Error, Debug)]
pub enum GeneratorError {
#[error("Invalid token: {0}")]
InvalidToken(String),
#[error("Formatting error: {0}")]
FormattingError(String),
#[error("Code generation failed: {0}")]
CodeGenerationFailed(String),
#[error("Unsupported construct: {0}")]
UnsupportedConstruct(String),
#[error("Invalid configuration: {0}")]
InvalidConfig(String),
}
pub type GeneratorResult<T> = Result<T, GeneratorError>;