mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2025-01-09 08:24:10 -08:00
Minor fixes
This commit is contained in:
parent
4d6c91aff8
commit
eaf31c1309
|
@ -69,7 +69,6 @@ class WasmBinaryRenderingVisitor implements WasmExpressionVisitor {
|
||||||
@Override
|
@Override
|
||||||
public void visit(WasmBlock expression) {
|
public void visit(WasmBlock expression) {
|
||||||
depth += expression.isLoop() ? 2 : 1;
|
depth += expression.isLoop() ? 2 : 1;
|
||||||
//depth++;
|
|
||||||
blockDepths.put(expression, depth);
|
blockDepths.put(expression, depth);
|
||||||
writer.writeByte(expression.isLoop() ? 0x02 : 0x01);
|
writer.writeByte(expression.isLoop() ? 0x02 : 0x01);
|
||||||
for (WasmExpression part : expression.getBody()) {
|
for (WasmExpression part : expression.getBody()) {
|
||||||
|
@ -78,7 +77,6 @@ class WasmBinaryRenderingVisitor implements WasmExpressionVisitor {
|
||||||
writer.writeByte(0x0F);
|
writer.writeByte(0x0F);
|
||||||
blockDepths.remove(expression);
|
blockDepths.remove(expression);
|
||||||
depth -= expression.isLoop() ? 2 : 1;
|
depth -= expression.isLoop() ? 2 : 1;
|
||||||
//depth--;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -122,7 +122,7 @@ public class WasmBinaryWriter {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void writeSignedLEB(long v) {
|
public void writeSignedLEB(long v) {
|
||||||
alloc(5);
|
alloc(10);
|
||||||
while (true) {
|
while (true) {
|
||||||
int digit = (int) (v & 0x7F);
|
int digit = (int) (v & 0x7F);
|
||||||
v >>= 7;
|
v >>= 7;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user