mirror of
https://github.com/gbdev/rgbds.git
synced 2026-10-06 12:15:39 +00:00
Addresses are 16-bit in .map files, consistent with .sym files
This commit is contained in:
1 parent
4ada3e85d8
commit
57c9bab3a5
1 file changed
+2
-2
+2
-2
@@ -450,9 +450,9 @@ static void writeMapSymbols(Section const §) {
|
|||||||
announced = true;
|
announced = true;
|
||||||
}
|
}
|
||||||
assume(std::holds_alternative<Label>(sym->data));
|
assume(std::holds_alternative<Label>(sym->data));
|
||||||
uint32_t address = std::get<Label>(sym->data).offset + sect.org;
|
uint16_t addr = static_cast<uint16_t>(std::get<Label>(sym->data).offset + sect.org);
|
||||||
// Space matches "\tSECTION: $xxxx ..."
|
// Space matches "\tSECTION: $xxxx ..."
|
||||||
fprintf(mapFile, "\t $%04" PRIx32 " = ", address);
|
fprintf(mapFile, "\t $%04" PRIx16 " = ", addr);
|
||||||
writeSymName(sym->name, mapFile);
|
writeSymName(sym->name, mapFile);
|
||||||
putc('\n', mapFile);
|
putc('\n', mapFile);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user