public override bool Equals(object obj) { if (!base.Equals(obj)) { return(false); } if (!(obj is ConvertFunction)) { return(false); } ConvertFunction other = (ConvertFunction)obj; if (other.targetType != targetType) { return(false); } return(true); }
/** the generated parser. Maintains a state and a value stack, currently with fixed maximum size. @param yyLex scanner. @return result of the last reduction, if any. @throws yyException on irrecoverable parse error. */ public Object yyparse (yyParser.yyInput yyLex) { if (yyMax <= 0) yyMax = 256; // initial size int yyState = 0; // state stack ptr int [] yyStates = new int[yyMax]; // state stack Object yyVal = null; // value stack ptr Object [] yyVals = new Object[yyMax]; // value stack int yyToken = -1; // current input int yyErrorFlag = 0; // #tks to shift int yyTop = 0; goto skip; yyLoop: yyTop++; skip: for (;; ++ yyTop) { if (yyTop >= yyStates.Length) { // dynamically increase int[] i = new int[yyStates.Length+yyMax]; yyStates.CopyTo (i, 0); yyStates = i; Object[] o = new Object[yyVals.Length+yyMax]; yyVals.CopyTo (o, 0); yyVals = o; } yyStates[yyTop] = yyState; yyVals[yyTop] = yyVal; if (debug != null) debug.push(yyState, yyVal); yyDiscarded: for (;;) { // discarding a token does not change stack int yyN; if ((yyN = yyDefRed[yyState]) == 0) { // else [default] reduce (yyN) if (yyToken < 0) { yyToken = yyLex.advance() ? yyLex.token() : 0; if (debug != null) debug.lex(yyState, yyToken, yyname(yyToken), yyLex.value()); } if ((yyN = yySindex[yyState]) != 0 && ((yyN += yyToken) >= 0) && (yyN < yyTable.Length) && (yyCheck[yyN] == yyToken)) { if (debug != null) debug.shift(yyState, yyTable[yyN], yyErrorFlag-1); yyState = yyTable[yyN]; // shift to yyN yyVal = yyLex.value(); yyToken = -1; if (yyErrorFlag > 0) -- yyErrorFlag; goto yyLoop; } if ((yyN = yyRindex[yyState]) != 0 && (yyN += yyToken) >= 0 && yyN < yyTable.Length && yyCheck[yyN] == yyToken) yyN = yyTable[yyN]; // reduce (yyN) else switch (yyErrorFlag) { case 0: yyerror(String.Format ("syntax error, got token `{0}'", yyname (yyToken)), yyExpecting(yyState)); if (debug != null) debug.error("syntax error"); goto case 1; case 1: case 2: yyErrorFlag = 3; do { if ((yyN = yySindex[yyStates[yyTop]]) != 0 && (yyN += Token.yyErrorCode) >= 0 && yyN < yyTable.Length && yyCheck[yyN] == Token.yyErrorCode) { if (debug != null) debug.shift(yyStates[yyTop], yyTable[yyN], 3); yyState = yyTable[yyN]; yyVal = yyLex.value(); goto yyLoop; } if (debug != null) debug.pop(yyStates[yyTop]); } while (-- yyTop >= 0); if (debug != null) debug.reject(); throw new yyParser.yyException("irrecoverable syntax error"); case 3: if (yyToken == 0) { if (debug != null) debug.reject(); throw new yyParser.yyException("irrecoverable syntax error at end-of-file"); } if (debug != null) debug.discard(yyState, yyToken, yyname(yyToken), yyLex.value()); yyToken = -1; goto yyDiscarded; // leave stack alone } } int yyV = yyTop + 1-yyLen[yyN]; if (debug != null) debug.reduce(yyState, yyStates[yyV-1], yyN, yyRule[yyN], yyLen[yyN]); yyVal = yyDefault(yyV > yyTop ? null : yyVals[yyV]); switch (yyN) { case 3: #line 105 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = (IExpression)yyVals[-1+yyTop]; } break; case 4: #line 109 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new BoolOperation (Operation.AND, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 5: #line 113 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new BoolOperation (Operation.OR, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 6: #line 117 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Negation ((IExpression)yyVals[0+yyTop]); } break; case 12: #line 132 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Comparison ((Operation)yyVals[-1+yyTop], (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 13: #line 138 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.EQ; } break; case 14: #line 139 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.NE; } break; case 15: #line 140 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.LT; } break; case 16: #line 141 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.GT; } break; case 17: #line 142 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.LE; } break; case 18: #line 143 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = Operation.GE; } break; case 22: #line 152 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = (IExpression)yyVals[-1+yyTop]; } break; case 23: #line 156 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArithmeticOperation (Operation.MUL, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 24: #line 160 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArithmeticOperation (Operation.DIV, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 25: #line 164 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArithmeticOperation (Operation.MOD, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 26: #line 168 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArithmeticOperation (Operation.ADD, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 27: #line 172 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArithmeticOperation (Operation.SUB, (IExpression)yyVals[-2+yyTop], (IExpression)yyVals[0+yyTop]); } break; case 28: #line 176 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Negative ((IExpression)yyVals[0+yyTop]); } break; case 33: #line 189 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Literal (yyVals[0+yyTop]); } break; case 34: #line 190 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Literal (yyVals[0+yyTop]); } break; case 35: #line 191 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Literal (yyVals[0+yyTop]); } break; case 37: #line 196 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Literal (true); } break; case 38: #line 197 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Literal (false); } break; case 39: #line 202 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ColumnReference ((string)yyVals[0+yyTop]); } break; case 40: #line 206 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ColumnReference (ReferencedTable.Parent, null, (string)yyVals[0+yyTop]); } break; case 41: #line 210 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ColumnReference (ReferencedTable.Parent, (string)yyVals[-3+yyTop], (string)yyVals[0+yyTop]); } break; case 42: #line 214 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ColumnReference (ReferencedTable.Child, null, (string)yyVals[0+yyTop]); } break; case 43: #line 218 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ColumnReference (ReferencedTable.Child, (string)yyVals[-3+yyTop], (string)yyVals[0+yyTop]); } break; case 48: #line 236 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Aggregation (cacheAggregationResults, aggregationRows, (AggregationFunction)yyVals[-3+yyTop], (ColumnReference)yyVals[-1+yyTop]); } break; case 49: #line 242 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Count; } break; case 50: #line 243 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Sum; } break; case 51: #line 244 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Avg; } break; case 52: #line 245 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Max; } break; case 53: #line 246 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Min; } break; case 54: #line 247 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.StDev; } break; case 55: #line 248 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = AggregationFunction.Var; } break; case 56: #line 253 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new IifFunction ((IExpression)yyVals[-5+yyTop], (IExpression)yyVals[-3+yyTop], (IExpression)yyVals[-1+yyTop]); } break; case 57: #line 257 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { long arg1 = (long) yyVals[-3+yyTop]; long arg2 = (long) yyVals[-1+yyTop]; yyVal = new SubstringFunction ((IExpression)yyVals[-5+yyTop], (int) arg1, (int) arg2); } break; case 58: #line 263 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new IsNullFunction ((IExpression)yyVals[-3+yyTop], (IExpression)yyVals[-1+yyTop]); } break; case 59: #line 267 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new LenFunction ((IExpression)yyVals[-1+yyTop]); } break; case 60: #line 271 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new TrimFunction ((IExpression)yyVals[-1+yyTop]); } break; case 61: #line 275 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ConvertFunction ((IExpression)yyVals[-3+yyTop], (string)yyVals[-1+yyTop]); } break; case 64: #line 287 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Comparison (Operation.EQ, (IExpression)yyVals[-2+yyTop], new Literal (null)); } break; case 65: #line 291 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Comparison (Operation.NE, (IExpression)yyVals[-3+yyTop], new Literal (null)); } break; case 66: #line 298 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Like ((IExpression)yyVals[-2+yyTop], (string)yyVals[0+yyTop]); } break; case 67: #line 302 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Negation (new Like ((IExpression)yyVals[-3+yyTop], (string)yyVals[-1+yyTop])); } break; case 68: #line 309 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new In ((IExpression)yyVals[-2+yyTop], (IList)yyVals[0+yyTop]); } break; case 69: #line 313 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new Negation (new In ((IExpression)yyVals[-3+yyTop], (IList)yyVals[0+yyTop])); } break; case 70: #line 319 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = yyVals[-1+yyTop]; } break; case 71: #line 324 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { yyVal = new ArrayList(); ((IList)yyVal).Add (yyVals[0+yyTop]); } break; case 72: #line 329 "/home/jeff/dev/dev_apps/sand/qca_designer/lib/ml-pnet-0.8.1/mcs-sources/class/System.Data/Mono.Data.SqlExpressions/Parser.jay" { ((IList)(yyVal = yyVals[-2+yyTop])).Add (yyVals[0+yyTop]); } break; #line default } yyTop -= yyLen[yyN]; yyState = yyStates[yyTop]; int yyM = yyLhs[yyN]; if (yyState == 0 && yyM == 0) { if (debug != null) debug.shift(0, yyFinal); yyState = yyFinal; if (yyToken < 0) { yyToken = yyLex.advance() ? yyLex.token() : 0; if (debug != null) debug.lex(yyState, yyToken,yyname(yyToken), yyLex.value()); } if (yyToken == 0) { if (debug != null) debug.accept(yyVal); return yyVal; } goto yyLoop; } if (((yyN = yyGindex[yyM]) != 0) && ((yyN += yyState) >= 0) && (yyN < yyTable.Length) && (yyCheck[yyN] == yyState)) yyState = yyTable[yyN]; else yyState = yyDgoto[yyM]; if (debug != null) debug.shift(yyStates[yyTop], yyState); goto yyLoop; } } }