fix while

This commit is contained in:
Qrakhen 2025-12-04 00:58:36 +01:00
parent e5a2c6db67
commit bef91ed928
3 changed files with 6 additions and 2 deletions

View File

@ -386,7 +386,6 @@ public class Digester : ISteppable<Token>
ParseExpression(); ParseExpression();
Consume(T.GroupClose, "Expected while condition to be placed inside parentheses. Missing ')'.", false); Consume(T.GroupClose, "Expected while condition to be placed inside parentheses. Missing ')'.", false);
long exit = EmitJump(Op.JumpIfFalse); long exit = EmitJump(Op.JumpIfFalse);
Emit(Op.Pop);
Statement(); Statement();
EmitLoop(start); EmitLoop(start);
PatchJump(exit); PatchJump(exit);

View File

@ -15,4 +15,9 @@ public class Obj(ValueType type) : IValue
} }
public override string ToString() => "Obj<undefined>"; public override string ToString() => "Obj<undefined>";
static Obj()
{
}
} }

View File

@ -9,7 +9,7 @@ namespace Qrakhen.Qamp.Core.Values;
public interface IValue public interface IValue
{ {
ValueType ValueType { get; } T ValueType { get; }
} }
[StructLayout(LayoutKind.Explicit, Size = 0x10)] [StructLayout(LayoutKind.Explicit, Size = 0x10)]