Add a standalone formula parser.
This is a fork of the EPPlus formula parser with all of the code that
evaluates formulas removed. AppSheet doesn't use this code as part of
its expression system, and removing it allows some significant
complexity and size reductions:
- Most of the dependencies on EPPlus Excel-specific code are
unnecessary and have been removed
- Parsing can be a static method; there's no need for interfaces for
everything
- There's no need for an IDisposable parser
- Many framework/NuGet dependencies are not necessary and have been
removed
In addition, a significant amount of cleanup work has been done:
- Nullable reference types have been enabled
- Code has been generally simplified where possible
- Unnecessary interfaces have been removed
Note that this does *not* change the fundamental design or
functionality of the formula parser. Notably:
- Parsing behavior should be completely unchanged, down to whatever
bugs the old system had
- NullReferenceException is still thrown for (some) malformed formulas
- The output is still a weird linked-list / tree hybrid
- Many functions that AppSheet doesn't support are still happily parsed
The idea is for this to be fully compatible with the existing
expression system, but faster and with fewer dependencies.
Change-Id: Ic687924a60b2673c24b39295ed684ed33d5cf9e4
Reviewed-on: https://gnocchi-internal-review.git.corp.google.com/c/third_party/epplus/+/208509
Reviewed-by: Mike Smith <mikeas@google.com>
Reviewed-by: Hughes Hilton <hugheshilton@google.com>
35 files changed