AST testing

This commit is contained in:
Michael Schimmel
2025-11-23 00:24:43 +01:00
parent c5167b8550
commit a052dfb20f
23 changed files with 792 additions and 1260 deletions
+3 -3
View File
@@ -240,7 +240,7 @@ var
placeholderType: IStaticType;
i: Integer;
begin
adr := Node.Identifier.Address;
adr := Node.Target.AsIdentifier.Address;
initType := TTypes.Unknown;
// Recursive lambda bootstrap logic
@@ -274,7 +274,7 @@ begin
if initType.Kind <> stUnknown then
FCurrentContext.SetType(adr.SlotIndex, initType);
newIdent := TAst.Identifier(Node.Identifier.Name, adr, initType);
newIdent := TAst.Identifier(Node.Target.AsIdentifier.Name, adr, initType);
Result := TAst.VarDecl(newIdent.AsIdentifier, newInitializer, initType, Node.IsBoxed);
end;
@@ -288,7 +288,7 @@ var
placeholderType: IStaticType;
i: Integer;
begin
newIdent := Accept(Node.Identifier);
newIdent := Accept(Node.Target);
targetType := newIdent.AsTypedNode.StaticType;
adr := newIdent.AsIdentifier.Address;