MCPcopy Index your code
hub / github.com/endbasic/endbasic / add_fixup

Method add_fixup

core/src/compiler/codegen.rs:163–166  ·  view source on GitHub ↗

Records a `fixup` that needs to be applied at `addr`.

(&mut self, addr: usize, fixup: Fixup)

Source from the content-addressed store, hash-verified

161
162 /// Records a `fixup` that needs to be applied at `addr`.
163 pub(super) fn add_fixup(&mut self, addr: usize, fixup: Fixup) {
164 let previous = self.fixups.insert(addr, fixup);
165 debug_assert!(previous.is_none(), "Cannot handle more than one fixup per address");
166 }
167
168 /// Gets the ID of a `constant`, adding it to the constants table if it isn't yet there.
169 pub(super) fn get_constant(&mut self, constant: ConstantDatum, pos: LineCol) -> Result<u16> {

Callers 2

compile_exprFunction · 0.80
compile_stmtFunction · 0.80

Calls 1

insertMethod · 0.45

Tested by

no test coverage detected