mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2024-12-22 08:14:09 -08:00
Wasm: fix issues when building with debugging information and optimizations enabled
This commit is contained in:
parent
9a9e7561b7
commit
013ba237b0
|
@ -985,7 +985,7 @@ class WasmBinaryRenderingVisitor implements WasmExpressionVisitor {
|
||||||
private void doEmitLocation() {
|
private void doEmitLocation() {
|
||||||
var address = positionToEmit + addressOffset;
|
var address = positionToEmit + addressOffset;
|
||||||
if (dwarfGenerator != null) {
|
if (dwarfGenerator != null) {
|
||||||
if (textLocationToEmit == null) {
|
if (textLocationToEmit == null || textLocationToEmit.getFileName() == null) {
|
||||||
dwarfGenerator.endLineNumberSequence(address);
|
dwarfGenerator.endLineNumberSequence(address);
|
||||||
} else {
|
} else {
|
||||||
dwarfGenerator.lineNumber(address, textLocationToEmit.getFileName(), textLocationToEmit.getLine());
|
dwarfGenerator.lineNumber(address, textLocationToEmit.getFileName(), textLocationToEmit.getLine());
|
||||||
|
@ -1010,7 +1010,7 @@ class WasmBinaryRenderingVisitor implements WasmExpressionVisitor {
|
||||||
methodStack.remove(methodStack.size() - 1);
|
methodStack.remove(methodStack.size() - 1);
|
||||||
}
|
}
|
||||||
while (commonPart < currentMethodStack.size()) {
|
while (commonPart < currentMethodStack.size()) {
|
||||||
var method = currentMethodStack.get(commonPart);
|
var method = currentMethodStack.get(commonPart++);
|
||||||
methodStack.add(method);
|
methodStack.add(method);
|
||||||
debugLines.start(method);
|
debugLines.start(method);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user