Fixed macro expansion
This commit is contained in:
@@ -51,7 +51,6 @@ type
|
||||
function VisitKeyword(const Node: IKeywordNode): IAstNode; override;
|
||||
|
||||
// Compile-time nodes (should not be present)
|
||||
function VisitMacroExpansionNode(const Node: IMacroExpansionNode): IAstNode; override;
|
||||
function VisitMacroDefinition(const Node: IMacroDefinitionNode): IAstNode; override;
|
||||
public
|
||||
constructor Create(const ADescriptor: IScopeDescriptor);
|
||||
@@ -148,12 +147,6 @@ begin
|
||||
raise Exception.Create('TTypeChecker: MacroDefinition node encountered.');
|
||||
end;
|
||||
|
||||
function TTypeChecker.VisitMacroExpansionNode(const Node: IMacroExpansionNode): IAstNode;
|
||||
begin
|
||||
// TypeChecker runs *after* expansion, so we just visit the body.
|
||||
Result := Accept(Node.ExpandedBody);
|
||||
end;
|
||||
|
||||
function TTypeChecker.VisitVariableDeclaration(const Node: IVariableDeclarationNode): IAstNode;
|
||||
var
|
||||
initType: IStaticType;
|
||||
|
||||
Reference in New Issue
Block a user