diff --git a/melior/src/ir/operation.rs b/melior/src/ir/operation.rs index 8ad1f9ef81..6fa3d65a13 100644 --- a/melior/src/ir/operation.rs +++ b/melior/src/ir/operation.rs @@ -228,9 +228,9 @@ impl<'c> Operation<'c> { unsafe { OperationRefMut::from_option_raw(mlirOperationGetNextInBlock(self.raw)) } } - /// Returns a reference to the next operation in the same block. + /// Returns a reference to the previous operation in the same block. pub fn previous_in_block(&self) -> Option> { - unsafe { OperationRef::from_option_raw(mlirOperationGetNextInBlock(self.raw)) } + todo!("mlirOperationGetPrevInBlock is not exposed in the C API") } /// Returns a reference to a parent operation.