From 9773495f1ab8a11194a21e1cf7b141c3da5cdfce Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Fri, 29 May 2020 14:26:48 -0400 Subject: NodeBase types constructed with astNodeType member set (#1363) * Maked Substituions derived from NodeBase * * Add astNodeTYpe field to NodeBase * Make Substitutions derived from NodeBase * Make all construction through ASTBuilder * Make getClassInfo non virtual (just uses the astNodeType) --- source/slang/slang-parser.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/slang/slang-parser.cpp') diff --git a/source/slang/slang-parser.cpp b/source/slang/slang-parser.cpp index a90d4bfc9..6fd51bea2 100644 --- a/source/slang/slang-parser.cpp +++ b/source/slang/slang-parser.cpp @@ -2834,10 +2834,10 @@ namespace Slang // This is a catch-all syntax-construction callback to handle cases where // a piece of syntax is fully defined by the keyword to use, along with // the class of AST node to construct. - static RefPtr parseSimpleSyntax(Parser* /*parser*/, void* userData) + static RefPtr parseSimpleSyntax(Parser* parser, void* userData) { SyntaxClassBase syntaxClass((ReflectClassInfo*) userData); - return (RefObject*) syntaxClass.createInstanceImpl(); + return (RefObject*) syntaxClass.createInstanceImpl(parser->astBuilder); } // Parse a declaration of a keyword that can be used to define further syntax. -- cgit v1.2.3