Sets an absolute source location for the given instruction. If no base source location has been set yet, records it at the same time.
(&mut self, inst: Inst, srcloc: SourceLoc)
| 451 | /// |
| 452 | /// If no base source location has been set yet, records it at the same time. |
| 453 | pub fn set_srcloc(&mut self, inst: Inst, srcloc: SourceLoc) { |
| 454 | let base = self.params.ensure_base_srcloc(srcloc); |
| 455 | self.stencil.srclocs[inst] = RelSourceLoc::from_base_offset(base, srcloc); |
| 456 | } |
| 457 | |
| 458 | /// Returns an absolute source location for the given instruction. |
| 459 | pub fn srcloc(&self, inst: Inst) -> SourceLoc { |
nothing calls this directly
no test coverage detected