Ejemplo n.º 1
0
        public override void Visit(ChainExpr expr)
        {
            if (ReferencesRootVariableVisitor.ReferencesRootVariable(expr))
            {
                _needsAsync = true;
                return;
            }

            // Some things can't be simplified by themselves, but they can be in the
            // context of a chain. If this chain doesn't need to be asynchronous, then
            // the next key or index won't need it either.
            if (NeedsAsyncByItselfVisitor.NeedsAsyncByItself(expr.Next))
            {
                _needsAsync = true;
                return;
            }
        }