public static void CollectSymbols(ModuleSymbolTable table, ExpressionEval eval)
        {
            var symbolCollector = new SymbolCollector(table, eval);

            symbolCollector.Walk();
        }
Beispiel #2
0
 public void Build(ExpressionEval eval)
 // This part only adds definition for the function and its overloads
 // to the walker list. It does NOT resolve return types or parameters.
 // Function body is not walked. For the actual function code walk
 // and the type resolution see FunctionWalker class.
 => SymbolCollector.CollectSymbols(this, eval);
 public Task BuildAsync(ExpressionEval eval, CancellationToken cancellationToken = default)
 // This part only adds definition for the function and its overloads
 // to the walker list. It does NOT resolve return types or parameters.
 // Function body is not walked. For the actual function code walk
 // and the type resolution see FunctionWalker class.
 => SymbolCollector.CollectSymbolsAsync(this, eval, cancellationToken);
        public static Task CollectSymbolsAsync(ModuleSymbolTable table, ExpressionEval eval, CancellationToken cancellationToken = default)
        {
            var symbolCollector = new SymbolCollector(table, eval);

            return(symbolCollector.WalkAsync(cancellationToken));
        }