tinyexpr-rs
Tiny recursive descent expression parser, compiler, and evaluation engine for math expressions.
This is a WIP port of TinyExpr to Rust. Current release only supports built-in system functions (trigonometry, algebraic operations, constants, etc.). See the tests
module for more examples.
Usage
# Cargo.toml
[]
= "0.1"
Example
extern crate tinyexpr;
Build instructions
cargo build
cargo run --example tinyexpr
Todo
- support for custom user function
- support for functions taking more than 2 parameters
- support closures
License
Licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)