示例#1
0
        public static IParser <SqlExpression> OrExpr <T>(IParser <T> factor)
            where T : SqlExpression
        {
            var orExpr =
                from left in factor
                from oper1 in SqlToken.Word("OR")
                from right in factor
                select new SqlAndOperExpression()
            {
                Left  = left,
                Oper  = "OR",
                Right = right
            };

            return(orExpr.CastParser <SqlExpression>().Or(factor.CastParser <SqlExpression>()));
        }
示例#2
0
 public static IParser <SqlExpression> MapSqlExpr <T>(this IParser <T> p)
 {
     return(p.CastParser <SqlExpression>());
 }