Skip to content

Commit

Permalink
fix(derive): absolute path references to Diagnostic (#118)
Browse files Browse the repository at this point in the history
  • Loading branch information
tailhook authored Feb 20, 2022
1 parent 9d50daf commit 6eb3d2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions miette-derive/src/related.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ impl Related {
quote! {
Self::#ident #display_pat => {
std::option::Option::Some(std::boxed::Box::new(
#rel.iter().map(|x| -> &(dyn Diagnostic) { &*x })
#rel.iter().map(|x| -> &(dyn miette::Diagnostic) { &*x })
))
}
}
Expand All @@ -69,7 +69,7 @@ impl Related {
let rel = &self.0;
Some(quote! {
fn related<'a>(&'a self) -> std::option::Option<std::boxed::Box<dyn std::iter::Iterator<Item = &'a dyn miette::Diagnostic> + 'a>> {
std::option::Option::Some(std::boxed::Box::new(self.#rel.iter().map(|x| -> &(dyn Diagnostic) { &*x })))
std::option::Option::Some(std::boxed::Box::new(self.#rel.iter().map(|x| -> &(dyn miette::Diagnostic) { &*x })))
}
})
}
Expand Down

0 comments on commit 6eb3d2d

Please sign in to comment.