Skip to content

Commit 9075ab7

Browse files
committed
filter and format interpreters are revisited
1 parent 7ddc655 commit 9075ab7

File tree

4 files changed

+234
-186
lines changed

4 files changed

+234
-186
lines changed

bear/src/modes/mod.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -281,11 +281,12 @@ mod impls {
281281
output: args::BuildSemantic,
282282
config: &config::Main,
283283
) -> Result<Self, WriterCreationError> {
284-
let interpreter = Box::new(semantic::interpreters::create(config));
284+
let interpreter = semantic::interpreters::create(config)
285+
.map_err(|err| WriterCreationError::Configuration(err.to_string()))?;
285286
let writer = output::OutputWriter::try_from((&output, &config.output))?;
286287

287288
Ok(Self {
288-
interpreter,
289+
interpreter: Box::new(interpreter),
289290
writer,
290291
})
291292
}

0 commit comments

Comments
 (0)