internal override Expression Visit(Expression expr) { if (expr == null) { return(expr); } if (HpcLinqExpression.IsConstant(expr)) { object val = ExpressionSimplifier.Evaluate(expr); if (val is IQueryable) { QueryNodeInfo nodeInfo; if (this.m_referencedQueryMap.TryGetValue(((IQueryable)val).Expression, out nodeInfo)) { string name = "side__" + this.m_idx; this.m_idx++; this.m_referencedQueries.Add(new Pair <string, DryadQueryNode>(name, nodeInfo.queryNode)); return(Expression.Parameter(expr.Type, name)); } throw new DryadLinqException(HpcLinqErrorCode.UnhandledQuery, String.Format(SR.UnhandledQuery, HpcLinqExpression.Summarize(expr))); } return(expr); } return(base.Visit(expr)); }
internal override Expression Visit(Expression expr) { if (expr == null) { return(expr); } if (HpcLinqExpression.IsConstant(expr)) { object val = ExpressionSimplifier.Evaluate(expr); if (val is IQueryable) { this.m_querySet.Add(((IQueryable)val).Expression); } return(expr); } return(base.Visit(expr)); }