diff options
author | Lars Wirzenius <liw@liw.fi> | 2023-12-01 10:50:04 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2023-12-01 11:44:52 +0200 |
commit | 1dde6e457ff07adf661d75ea0c1a34a3e66f10c0 (patch) | |
tree | 77a2a0908c2e229f8671f49556d82646cf8e77bb /src/error.rs | |
parent | add9bdb828833e6086b6f49df98fc655be897875 (diff) | |
download | subplot-1dde6e457ff07adf661d75ea0c1a34a3e66f10c0.tar.gz |
feat: make libdocgen fail if a binding lacks a doc string
The --merciful option allows this if the user really wants it.
Signed-off-by: Lars Wirzenius <liw@liw.fi>
Sponsored-by: author
Diffstat (limited to 'src/error.rs')
-rw-r--r-- | src/error.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/error.rs b/src/error.rs index 6859aa4..5c72879 100644 --- a/src/error.rs +++ b/src/error.rs @@ -50,6 +50,13 @@ pub enum SubplotError { #[error("binding file failed to parse: {0}")] BindingFileParseError(PathBuf, #[source] Box<SubplotError>), + /// Binding lacks documentation. + /// + /// Add a `doc` field to the binding with text the documents the + /// binding. + #[error("binding lacks documentation: {0}: {1} {2}")] + NoBindingDoc(PathBuf, crate::StepKind, String), + /// Scenario step does not match a known binding /// /// This may be due to the binding missing entirely, or that the |