using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ExpressionsParser {
///
/// The exception that is thrown when lambda expression parse error occurs
///
public class LambdaParserException : Exception {
///
/// Lambda expression
///
public string Expression { get; private set; }
///
/// Parser position where syntax error occurs
///
public int Index { get; private set; }
public LambdaParserException(string expr, int idx, string msg)
: base( string.Format("{0} at {1}: {2}", msg, idx, expr) ) {
Expression = expr;
Index = idx;
}
}
}