Skip to content

Commit

Permalink
Fix display of non-addressable symbols in HTML export
Browse files Browse the repository at this point in the history
If a symbol is marked as "exported", it is added to the symbol table
generated at the end of the HTML output.  If the symbol identifies a
non-addressable location, we need to show that.

Also, added a header row.
  • Loading branch information
fadden committed Jan 12, 2022
1 parent 55c80fb commit 740eeff
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion SourceGen/Exporter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1088,11 +1088,18 @@ private string GenerateHtmlSymbolTable() {
}
if (count == 0) {
sb.Append("<table>\r\n");
sb.Append(" <tr><th>Label</th><th>Value</th></tr>");
}
sb.Append(" <tr>");
sb.Append("<td><a href=\"#" + LABEL_LINK_PREFIX + sym.Label + "\">" +
sym.Label + "</a></td>");
sb.Append("<td><code>" + mFormatter.FormatHexValue(sym.Value, 2) + "</code></td>");
sb.Append("<td><code>");
if (sym.Value != Address.NON_ADDR) {
sb.Append(mFormatter.FormatHexValue(sym.Value, 2));
} else {
sb.Append(Address.NON_ADDR_STR);
}
sb.Append("</code></td>");
sb.Append("</tr>\r\n");
count++;
}
Expand Down

0 comments on commit 740eeff

Please sign in to comment.