the really small

RISC OS | Development


This is a port of ExprEval. From the supplied documentation:

ExprEval is a mostly a C based expression evaluation library. The only C++ part is the C++ Wrapper which encapsulates the complexity of the library usage.

ExprEval supports the parsing of multiple expressions in a single expression string. Each sub-expression must end with a semicolon. It also supports the use of variables, constants, and functions. Functions can take multiple arguments. These arguments can also be expressions.

ExprEval is very fast. It first parses the expression string into a tree of actions to take. After it has been parsed, an expression can be evaluated many times over an over.

In order to increase evaluation speed, constants and functions are not stored in the parsed tree as names, but instead as values or pointers to the function routines. Only variables are stored as names. For this reason, constants and functions are used at parse time only, and variables are used at evaluation time.

Functions, variables, and constants are stored in their own seperate lists. This makes is where the lists can be shared among multiple expression objects. A function list can add all the functions needed, and then be added to each expression object, instead of added each needed function to each object. The same goes for constant lists. Variable lists make it where one expression can depend on a variable set in another.



  Version Size Date Notes
Archive 1.00 82K 20-Nov-2005 First release.

© Copyright 1995-2018 Richard Windley and Broad Oak Studios

Contact Us | Privacy | Cookies