Move to the previous instruction in the same block and return it. - If the cursor was positioned after a block, go to the last instruction in that block. - If there are no more instructions in the block, go to the `Before(block)` position and return `None`. - If the cursor wasn't pointing anywhere, keep doing that. This method will never move the cursor to a different block. # Examples The `pr
(&mut self)
| 518 | /// } |
| 519 | /// ``` |
| 520 | fn prev_inst(&mut self) -> Option<ir::Inst> { |
| 521 | let pos = self.prev_inst_position()?; |
| 522 | self.set_position(pos); |
| 523 | self.current_inst() |
| 524 | } |
| 525 | |
| 526 | /// Insert an instruction at the current position. |
| 527 | /// |
no test coverage detected