diff --git a/ClosedXML/Excel/CalcEngine/CalcEngine.cs b/ClosedXML/Excel/CalcEngine/CalcEngine.cs
index 07a5447..1b18b15 100644
--- a/ClosedXML/Excel/CalcEngine/CalcEngine.cs
+++ b/ClosedXML/Excel/CalcEngine/CalcEngine.cs
@@ -1,307 +1,287 @@
-using System;
-using System.Collections.Generic;
-using System.Globalization;
-using ClosedXML.Excel.CalcEngine.Functions;
-
-namespace ClosedXML.Excel.CalcEngine
-{
- ///
- /// CalcEngine parses strings and returns Expression objects that can
- /// be evaluated.
- ///
- ///
- /// This class has three extensibility points:
- /// Use the DataContext property to add an object's properties to the engine scope.
- /// Use the RegisterFunction method to define custom functions.
- /// Override the GetExternalObject method to add arbitrary variables to the engine scope.
- ///
- internal class CalcEngine
- {
+using System;
+using System.Reflection;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Globalization;
+using System.Diagnostics;
+using System.Text;
+using System.Text.RegularExpressions;
+using ClosedXML.Excel.CalcEngine;
+using ClosedXML.Excel.CalcEngine.Functions;
+
+namespace ClosedXML.Excel.CalcEngine {
+ ///
+ /// CalcEngine parses strings and returns Expression objects that can
+ /// be evaluated.
+ ///
+ ///
+ /// This class has three extensibility points:
+ /// Use the DataContext property to add an object's properties to the engine scope.
+ /// Use the RegisterFunction method to define custom functions.
+ /// Override the GetExternalObject method to add arbitrary variables to the engine scope.
+ ///
+ internal class CalcEngine {
//---------------------------------------------------------------------------
-
- #region ** ctor
-
- public CalcEngine()
- {
- CultureInfo = CultureInfo.InvariantCulture;
- _tkTbl = GetSymbolTable();
- Functions = GetFunctionTable();
- Variables = new Dictionary(StringComparer.OrdinalIgnoreCase);
- _cache = new ExpressionCache(this);
- OptimizeExpressions = true;
-#if DEBUG
- //this.Test();
-#endif
- }
-
- #endregion
-
- //---------------------------------------------------------------------------
-
- #region ** fields
+ #region ** fields
// members
- private string _expr; // expression being parsed
- private int _len; // length of the expression being parsed
- private int _ptr; // current pointer into expression
- private Token _token; // current token being parsed
- private Dictionary