Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
raviqqe committed Dec 6, 2023
1 parent e909750 commit c1ea013
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions macro/src/dialect/operation/accessors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,7 @@ impl<'a> OperationField<'a> {
quote! { self.operation.attribute(#name).is_some() }
} else {
// TODO Handle returning `melior::Attribute`.
quote! {
#[allow(clippy::needless_question_mark)]
Ok(self.operation.attribute(#name)?.try_into()?)
}
quote! { Ok(self.operation.attribute(#name)?.try_into()?) }
})
}
})
Expand Down Expand Up @@ -229,6 +226,7 @@ impl<'a> OperationField<'a> {
let return_type = &self.kind.return_type()?;
self.getter_impl()?.map(|body| {
quote! {
#[allow(clippy::needless_question_mark)]
pub fn #ident(&self, context: &'c ::melior::Context) -> #return_type {
#body
}
Expand Down

0 comments on commit c1ea013

Please sign in to comment.