1
0
mirror of https://github.com/fadden/6502bench.git synced 2025-09-27 03:16:55 +00:00

Minor tweaks

Note that address region isolation doesn't prevent explicit label
references from working (add update the test to prove it).

Added a note about pre-label xrefs.
This commit is contained in:
Andy McFadden
2024-05-22 14:01:02 -07:00
parent 7a7ff44d3a
commit 3b20566b10
9 changed files with 28 additions and 11 deletions

View File

@@ -3947,7 +3947,8 @@ namespace SourceGen {
return;
}
int lineIndex = mMainWin.CodeListView_GetFirstSelectedIndex();
LineListGen.Line.Type type = CodeLineList[lineIndex].LineType;
LineListGen.Line line = CodeLineList[lineIndex];
LineListGen.Line.Type type = line.LineType;
if (type != LineListGen.Line.Type.Code &&
type != LineListGen.Line.Type.Data &&
type != LineListGen.Line.Type.EquDirective &&
@@ -3960,10 +3961,10 @@ namespace SourceGen {
// Find the appropriate xref set.
if (type == LineListGen.Line.Type.LocalVariableTable) {
DefSymbol defSym = CodeLineList.GetLocalVariableFromLine(CodeLineList[lineIndex]);
DefSymbol defSym = CodeLineList.GetLocalVariableFromLine(line);
xrefs = (defSym == null) ? null : defSym.Xrefs;
} else {
int offset = CodeLineList[lineIndex].FileOffset;
int offset = line.FileOffset;
if (offset < 0) {
// EQU in header
int index = LineListGen.DefSymIndexFromOffset(offset);