Add address comments for methods and vtables
This commit is contained in:
parent
63ad20456c
commit
da98988090
@ -1,4 +1,4 @@
|
|||||||
import { formatType } from './common';
|
import { formatType, toHex } from './common';
|
||||||
|
|
||||||
export class Method {
|
export class Method {
|
||||||
readonly self: string;
|
readonly self: string;
|
||||||
@ -31,7 +31,7 @@ export class Method {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Generate Variable Definition
|
// Generate Variable Definition
|
||||||
generateDefinition(nameSuffix?: string) {
|
generateDefinition(showAddress: bool, nameSuffix?: string) {
|
||||||
return `${this.getType()} ${this.getName()}${nameSuffix !== undefined ? nameSuffix : ''};\n`;
|
return `${this.getType()} ${this.getName()}${nameSuffix !== undefined ? nameSuffix : ''}; // ${toHex(this.address)}\n`;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -115,7 +115,7 @@ export class VTable implements Property {
|
|||||||
// Pointers
|
// Pointers
|
||||||
if (this.#address !== null) {
|
if (this.#address !== null) {
|
||||||
// Base
|
// Base
|
||||||
out += `extern ${this.#getName()} *${this.#getName()}_base;\n`;
|
out += `extern ${this.#getName()} *${this.#getName()}_base; // ${toHex(this.#address)}\n`;
|
||||||
// Methods
|
// Methods
|
||||||
for (let i = 0; i < this.#methods.length; i++) {
|
for (let i = 0; i < this.#methods.length; i++) {
|
||||||
const info = this.#methods[i];
|
const info = this.#methods[i];
|
||||||
|
Loading…
Reference in New Issue
Block a user