expressive/CHANGELOG.md

522 lines
15 KiB
Markdown
Raw Normal View History

2019-03-20 13:37:07 +00:00
# Change Log
## Unreleased
2021-07-21 10:45:35 +00:00
### Notes
### Added
### Removed
2022-01-13 12:54:34 +00:00
### Changed
### Fixed
### Deprecated
### Contributors
2023-06-01 13:06:34 +00:00
## [11.0.0](https://github.com/ISibboI/evalexpr/compare/10.0.0...11.0.0) - 2023-06-01
### Added
* Builtin function `math::abs` (#130)
* A CLI for evaluating expressions. Install via `cargo install evalexpr`. (#133)
* The ability to parse integers from hex literals (#131)
### Contributors
2023-05-27 08:08:37 +00:00
My warmhearted thanks goes to:
2023-06-01 12:59:29 +00:00
* [Heki](https://github.com/LinuxHeki)
* [Kaspar Schleiser](https://github.com/kaspar030)
2023-05-27 08:08:37 +00:00
2023-05-21 07:30:00 +00:00
## [10.0.0](https://github.com/ISibboI/evalexpr/compare/9.1.0...10.0.0) - 2023-05-21
### Added
* Builtin functions can now be disabled (#129)
### Contributors
My warmhearted thanks goes to:
* [hexofyore](https://github.com/hexofyore)
2023-05-16 15:20:53 +00:00
## [9.1.0](https://github.com/ISibboI/evalexpr/compare/9.0.0...9.1.0) - 2023-05-16
### Added
2023-05-21 07:30:00 +00:00
* Builtin functions `contains` and `contains_any` (#127)
2023-05-16 15:20:53 +00:00
### Contributors
My warmhearted thanks goes to:
2023-05-21 07:30:00 +00:00
* [nickisyourfan](https://github.com/nickisyourfan)
2023-05-16 15:20:53 +00:00
2023-04-13 12:48:45 +00:00
## [9.0.0](https://github.com/ISibboI/evalexpr/compare/8.2.0...9.0.0) - 2023-04-13
2023-04-13 11:47:22 +00:00
### Fixed
2023-04-13 12:48:45 +00:00
* Taking numbers to negative powers gave unexpected results (#120)
* **Update MSRV to 1.56.1 (2021 edition release)** to allow builds with the latest versions of all dependencies.
2023-04-13 11:47:22 +00:00
### Contributors
My warmhearted thanks goes to:
2023-04-13 12:48:45 +00:00
* [Pham Nhat Huy](https://github.com/012e)
2023-04-13 11:47:22 +00:00
2023-04-13 11:09:14 +00:00
## [8.2.0](https://github.com/ISibboI/evalexpr/compare/8.1.0...8.2.0) - 2023-04-13
### Added
* `EvalExprError` now derives `Clone` (#116)
### Changed
* Occurrences of `f64` and `i64` have been replaced with the type aliases `FloatType` and `IntType` where applicable (#113)
### Contributors
My warmhearted thanks goes to:
2023-04-13 12:48:45 +00:00
* [Natan Freeman](https://github.com/NatanFreeman)
* [Claus Matzinger](https://github.com/celaus)
2023-04-13 11:09:14 +00:00
2022-07-22 09:09:17 +00:00
## [8.1.0](https://github.com/ISibboI/evalexpr/compare/8.0.0...8.1.0) - 2022-07-22
### Added
2022-07-22 09:17:26 +00:00
* Get all variables or variable/value pairs in a context via a new trait `IterateVariablesContext` (#108)
2022-07-22 09:09:17 +00:00
* Functions `iter_(read/write)_variable_identifiers`, which iterate over all `ReadVariableIdentifier`s or all `WriteVariableIdentifier`s in an operator tree (#110)
### Contributors
My warmhearted thanks goes to:
2022-07-22 09:17:26 +00:00
* [egel557](https://github.com/egel557)
2022-07-22 09:09:17 +00:00
* [Tobias Schmitt](https://github.com/tsmt09)
2022-07-06 08:25:51 +00:00
## [8.0.0](https://github.com/ISibboI/evalexpr/compare/7.2.0...8.0.0) - 2022-07-06
### Added
* Builtin functions to check for nan, infinity and subnormality in floats (#101)
* Builtin random function (#102)
* Implement `TryFrom<Value>` for all types a value can hold (#105)
* Split VariableIdentifier node into read and write variants (#106)
### Contributors
2022-04-07 13:20:26 +00:00
My warmhearted thanks goes to:
* [Ophir LOJKINE](https://github.com/lovasoa)
* [Joe Grund](https://github.com/jgrund)
2022-07-06 08:14:29 +00:00
* [Luka Maljic](https://github.com/malj)
2022-04-07 13:20:26 +00:00
2022-03-16 14:18:32 +00:00
## [7.2.0](https://github.com/ISibboI/evalexpr/compare/7.1.1...7.2.0) - 2022-03-16
### Added
* The builtin function `if`, which mimics the if-else construct existing in many programming languages.
### Contributors
My warmhearted thanks goes to:
* [Ophir LOJKINE](https://github.com/lovasoa)
## [7.1.1](https://github.com/ISibboI/evalexpr/compare/7.1.0...7.1.1) - 2022-03-14
2022-03-14 11:25:37 +00:00
### Fixed
* Set regex minimum version to `1.5.5`, as the previous versions contains a security vulnerability.
See https://groups.google.com/g/rustlang-security-announcements/c/NcNNL1Jq7Yw?pli=1.
This vulnerability does not affect this crate as of now, but if we ever allow passing parameters to the regex engine, it might.
2022-03-13 10:30:08 +00:00
## [7.1.0](https://github.com/ISibboI/evalexpr/compare/7.0.1...7.1.0) - 2022-03-13
### Added
* Bit shift functions `shl` and `shr`, same as Rust's shift functions on `i64`.
### Contributors
My warmhearted thanks goes to
* [Diane Sparks](https://github.com/FractalDiane)
2022-02-20 07:57:39 +00:00
## [7.0.1](https://github.com/ISibboI/evalexpr/compare/7.0.0...7.0.1) - 2022-02-20
### Changed
* Updated the optional dependencies, and fixed them to a minimum tested version.
For simplicity, I fixed them to the newest version, but since I export none of them, this is luckily not breaking.
* Updated the dev-dependencies.
2022-01-13 12:54:34 +00:00
## [7.0.0](https://github.com/ISibboI/evalexpr/compare/6.6.0...7.0.0) - 2022-01-13
2021-07-21 10:45:35 +00:00
### Changed
2022-02-20 07:57:39 +00:00
* Made the `EvalexprError` enum `non_exhaustive`.
2021-07-21 10:45:35 +00:00
### Fixed
* Expressions that have dangling parenthese expressions such as `4(5)` now produce an error.
2021-07-21 10:45:35 +00:00
### Contributors
2022-01-13 12:54:34 +00:00
My warmhearted thanks goes to
* [dbr/Ben](https://github.com/dbr)
2021-10-13 11:31:02 +00:00
## [6.6.0](https://github.com/ISibboI/evalexpr/compare/6.5.0...6.6.0) - 2021-10-13
### Added
* Bitwise operators as builtin functions `bitand`, `bitor`, `bitxor`, `bitnot` (#88)
* Public immutable and mutable accessor functions to the operator and children of a Node.
### Contributors
My warmhearted thanks goes to
* [Michał Hanusek](https://github.com/hanusek)
* [Kai Giebeler](https://github.com/kawogi)
2021-08-16 10:37:34 +00:00
## [6.5.0](https://github.com/ISibboI/evalexpr/compare/6.4.0...6.5.0) - 2021-08-16
### Added
* Make `Function::new` able to accept closures (thanks to Jakub Dąbek)
### Contributors
My warmhearted thanks goes to
* [Jakub Dąbek](https://github.com/jakubdabek)
* [LonnonjamesD](https://github.com/LonnonjamesD)
2021-07-21 10:45:35 +00:00
## [6.4.0](https://github.com/ISibboI/evalexpr/compare/6.3.0...6.4.0) - 2021-07-21
### Notes
2021-07-13 12:08:09 +00:00
* Minimum supported Rust version (MSRV) increased to `1.46.0`
* Increased test coverage by adding more test and ignoring untestable files
2019-08-30 07:26:37 +00:00
### Added
2021-07-21 10:42:50 +00:00
* Allow scientific notation in float literals
2019-08-30 07:26:37 +00:00
### Changed
* Made some functions `const`. This increased the MSRV
2019-08-30 07:26:37 +00:00
### Fixed
* `eval_number` methods returned `EvalexprError::ExpectedFloat` before, now they correctly return `EvalexprError::ExpectedNumber`
2019-08-30 07:26:37 +00:00
### Contributors
2021-07-21 10:42:50 +00:00
My warmhearted thanks goes to
* [Dennis Marttinen](https://github.com/twelho)
2021-07-06 12:57:22 +00:00
## [6.3.0](https://github.com/ISibboI/evalexpr/compare/6.2.1...6.3.0) - 2021-07-06
### Added
* Implement more builtin math methods
### Contributors
My warmhearted thanks goes to
* [Magnus Ulimoen](https://github.com/mulimoen)
2021-06-24 09:12:50 +00:00
## [6.2.0](https://github.com/ISibboI/evalexpr/compare/6.1.1...6.2.0) - 2021-06-24
### Notes
* Increased test coverage
### Added
* Implemented `Clone` for `HashMapContext`
### Contributors
My warmhearted thanks goes to
* [Magnus Ulimoen](https://github.com/mulimoen)
2021-06-22 08:23:23 +00:00
## [6.1.1](https://github.com/ISibboI/evalexpr/compare/6.1.0...6.1.1) - 2021-06-22
### Fixed
2021-06-24 09:12:50 +00:00
* Improved syntax of documentation
2021-06-22 08:23:23 +00:00
2021-06-02 15:19:01 +00:00
## [6.1.0](https://github.com/ISibboI/evalexpr/compare/6.0.0...6.1.0) - 2021-06-02
### Added
* Macro `math_consts_context` adding all of Rust's `f64` constants
* All common math functions implemented by Rust's `f64` are now builtin
* Continuous integration and test coverage report
### Contributors
My warmhearted thanks goes to
* [Edwin](https://github.com/olback)
2021-06-02 15:08:32 +00:00
## [6.0.0](https://github.com/ISibboI/evalexpr/compare/5.1.0...6.0.0) - 2021-05-28
### Added
* `#![forbid(unsafe_code)]`
* Made `Function` derive `Clone`
* Ensure that `Function` implements `Send` and `Sync`
### Removed
* `Cargo.lock`
### Changed
* Decomposed `Context` into `Context`, `ContextWithMutableVariables` and `ContextWithMutableFunctions`
* Replaced the `get_function` method of `Context` with a `call_function` method
### Contributors
2021-06-02 15:19:01 +00:00
My warmhearted thanks goes to
2021-06-02 15:08:32 +00:00
* [dvtomas](https://github.com/dvtomas)
## [5.1.0](https://github.com/ISibboI/evalexpr/compare/5.0.5...5.1.0) - 2021-05-28
### Added
* Make `Node` cloneable
### Contributors
2021-06-02 15:19:01 +00:00
My warmhearted thanks goes to
2021-06-02 15:08:32 +00:00
* [dvtomas](https://github.com/dvtomas)
2019-09-13 15:35:01 +00:00
## [5.0.5](https://github.com/ISibboI/evalexpr/compare/5.0.4...5.0.5) - 2019-09-13
### Fixed
* is-it-maintained badges had wrong repository definitions
2019-09-13 15:37:10 +00:00
* maintenance status was given wrongly
2019-09-13 15:38:15 +00:00
* move maintenance status to top
2019-09-13 15:35:01 +00:00
## [5.0.4](https://github.com/ISibboI/evalexpr/compare/5.0.3...5.0.4) - 2019-09-13
### Added
* maintenance badge
* is-it-maintained badges
2019-08-30 09:51:20 +00:00
## [5.0.3](https://github.com/ISibboI/evalexpr/compare/5.0.2...5.0.3) - 2019-08-30
### Fixed
* The `!=` operator was wrongfully parsed as Token::Eq
### Contributors
2019-08-30 09:53:53 +00:00
* [slientgoat](https://github.com/slientgoat)
2019-08-30 09:51:20 +00:00
## [5.0.2](https://github.com/ISibboI/evalexpr/compare/5.0.1...5.0.2) - 2019-08-30
### Changed
* Removed target.bench.dev-dependencies completely, as they can be just listed under the normal dev-dependencies
2019-08-30 07:50:45 +00:00
## [5.0.1](https://github.com/ISibboI/evalexpr/compare/5.0.0...5.0.1) - 2019-08-30
### Fixed
* Bench dependencies are now dev-dependencies so they are not listed on crates.io as normal dependencies anymore
2019-08-30 07:26:37 +00:00
## [5.0.0](https://github.com/ISibboI/evalexpr/compare/4.1.0...5.0.0) - *'Sanity'* - 2019-08-30
### Notes
Finally, 'Sanity' has been released, including a huge bunch of new features.
Notably, and providing a reason for the name of this release, function call and tuple semantics have improved a lot.
Functions now always take exactly one argument, but this can then be a tuple.
It is now possible to construct tuples of tuples, such that mode complex values can be constructed.
As of now there is no way to deconstruct them though.
A lot has been done on string processing, special thanks for that goes to [bittrance](https://github.com/bittrance).
Specifically, under the feature flag `regex_support` two regex functions for strings are hiding now.
Also, the operators `+` and comparison operators have been fitted to support strings.
Thanks to [lovasoa](https://github.com/lovasoa), we now have a nice macro for context creation.
Thanks to [Atul9](https://github.com/Atul9), the crate is now Rust 2018 compliant.
Thanks to [mestachs'](https://github.com/mestachs) request, we now have functions to iterate over identifiers within an expression.
Internally, the structure of the operator tree changed from being `&dyn`-based to being `enum`-based.
Also, we have benchmarks now to observe performance changes in future releases.
### Added
2019-04-13 16:27:53 +00:00
* Iterator over all identifiers within an expression, including duplicates
* Iterators over only variable or only function identifiers within an expression, including duplicates
2019-04-13 16:27:53 +00:00
* Overload the `+` operator to concatenate strings
* Overload `<`, `<=`, `>` and `>=` for strings using lexical ordering (Note: `==` and `!=` compare strings as expected)
* Add `len`, `str::regex_matches`, `str::regex_replace`, `str::to_lowercase`, `str::to_uppercase`, `str::trim` functions for strings
* Add a macro for more convenient definition of contexts including the direct definition of static contexts
2019-08-29 07:02:13 +00:00
* Add API for value decomposition
2019-08-29 07:53:38 +00:00
* Allow using context operations in `eval` calls without context
* Operator assignment operators for each binary operation (`+=`, `-=`, ...)
* The `Operator` enum is now public for better error types
2019-08-29 15:43:14 +00:00
* Benchmarks for observing performance of future releases
### Removed
2019-08-29 07:02:13 +00:00
* Function arguments are not decomposed anymore.
The function implementation will receive exactly one argument now.
This allows the function to be called on a tuple properly.
### Changed
2019-08-29 07:02:13 +00:00
* Operators are an enum now instead of trait objects
* Update to Rust 2018
2019-08-30 07:33:42 +00:00
* Updated dependencies
2019-08-29 07:02:13 +00:00
### Fixed
2019-08-29 07:02:13 +00:00
* Allow variable assignments in eval calls without context.
A `HashMapContext` is created automatically now.
* The error string for `ExpectedNumber` was wrong
* Operators panicked when adding a number to a string
2019-08-30 07:26:37 +00:00
* Some documentation was not updated for the 4.x releases
### Contributors
My warmhearted thanks goes to
* [bittrance](https://github.com/bittrance)
* [lovasoa](https://github.com/lovasoa)
2019-08-30 07:26:37 +00:00
* [Atul9](https://github.com/Atul9)
* [mestachs](https://github.com/mestachs)
2019-04-13 16:27:53 +00:00
## [4.1.0](https://github.com/ISibboI/evalexpr/compare/4.0.0...4.1.0) - 2019-03-31
### Added
* Export `expect_function_argument_amount`
## [4.0.0](https://github.com/ISibboI/evalexpr/compare/3.1.0...4.0.0) - 2019-03-30
### Added
* String constants
2019-03-28 14:42:11 +00:00
## [3.1.0](https://github.com/ISibboI/evalexpr/compare/3.0.0...3.1.0) - 2019-03-28
### Added
* Add serde support to `HashMapContext`
* Make `HashMapContext` derive `Default` and `Debug`
2019-03-28 14:42:11 +00:00
### Changed
* Changed name of serde feature flag to `serde_support`
## [3.0.0](https://github.com/ISibboI/evalexpr/compare/2.0.0...3.0.0) - 2019-03-28
### Notes
2019-03-28 10:55:27 +00:00
The 3.0.0 update transforms the expression evaluator `evalexpr` to a tiny scripting language.
It allows assignments and chaining of expressions.
Some changes in this update are breaking, hence the major release.
2019-03-27 18:14:24 +00:00
### Added
2019-03-28 10:55:27 +00:00
* Methods `Node::eval_<type>_with_context_mut` and crate level `eval_<type>_with_context_mut`
* Empty type and corresponding shortcut methods. The empty type is emitted by empty expressions or empty subexpressions `()`.
* The assignment operator `=`
* The expression chaining operator `;`
2019-03-27 18:14:24 +00:00
### Removed
* Generic arguments from `Context` traits are now static to allow using trait objects of `Context`
2019-03-28 10:55:27 +00:00
* `EvalexprError::EmptyExpression` is not required anymore since empty expressions now evaluate to the empty type
2019-03-27 18:14:24 +00:00
### Changed
* Merge `ContextMut` trait into `Context` trait
## [2.0.0](https://github.com/ISibboI/evalexpr/compare/1.2.0...2.0.0) - 2019-03-28
2019-03-27 18:14:24 +00:00
2019-03-27 18:27:44 +00:00
### Notes
The 2.0.0 update is the first step to transform evalexpr to a tiny scripting language with support of at least variable assignment.
The main change for now is that `Configuration` is called `Context`, which seems to be a more proper naming for a set of variables that can not only be read, but also manipulated via expressions.
This update includes further renamings and some inconsistencies in the API were fixed.
For more details, see the following subsections.
### Added
* Add the `ContextMut` trait, that is a manipulable configuration/context
* Add `ContextNotManipulable` error variant for the `EmptyContext`
2019-03-27 17:19:05 +00:00
* Make the `TupleType` alias public
* Add the `ValueType` enum that represents the type of a value for easier comparisons and matchings
* Add `EvalexprResult<T>` type that uses the `EvalexprError` type (renamed from `Error`)
* Add `Node::eval_number` and `Node::eval_number_with_context` to evaluate to int or float and silently converting to float
* Add `eval_number` and `eval_number_with_context` crate methods to evaluate to int or float and silently converting to float
### Changed
2019-03-27 15:19:56 +00:00
* Get rid of some unwraps to improve safety
2019-03-27 17:19:05 +00:00
* Rename `Error` to `EvalexprError`
* Rename `Configuration` to `Context`
* Rename `HashMapConfiguration` to `HashMapContext` and `EmptyConfiguration` to `EmptyContext`
* Rename `Value::as_float` to `Value::as_number` and add new `Value::as_float` that fails if value is an integer
2019-03-27 15:19:56 +00:00
2019-03-23 14:15:48 +00:00
## [1.2.0](https://github.com/ISibboI/evalexpr/compare/1.1.0...1.2.0) - 2019-03-23
2019-03-20 15:43:06 +00:00
### Added
2019-03-23 10:46:52 +00:00
* Add `serde` feature
* Implement `serde::de::Deserialize` for `Node`
* Document `serde` usage
* Add custom error type with a `String` message
2019-03-23 10:46:52 +00:00
2019-03-20 15:43:06 +00:00
### Changed
2019-03-23 14:15:48 +00:00
* Highlighting in documentation
2019-03-20 15:43:06 +00:00
## [1.1.0](https://github.com/ISibboI/evalexpr/compare/1.0.0...1.1.0) - 2019-03-20
2019-03-20 13:37:07 +00:00
### Added
* Internal aliases `IntType` and `FloatType` used by the `Value` enum are now public
* Type alias `TupleType` used to represent tuples was added
* Error types like `Error::ExpectedInt` for expecting each value type were added
* Shortcut functions like `eval_int` or `eval_int_with_configuration` to evaluate directly into a value type were added
* Documentation for the shortcut functions was added
2019-03-20 15:43:06 +00:00
* Functions to decompose `Value`s were added and documented
2019-03-20 13:37:07 +00:00
### Removed
* Integration tests were removed from shipped crate
2019-03-20 13:37:07 +00:00
### Fixed
* Wording of some documentation items was changed to improve readability
2019-03-20 13:37:07 +00:00
## [1.0.0](https://github.com/ISibboI/evalexpr/tree/1.0.0) - 2019-03-20
2022-04-07 13:20:26 +00:00
* First stable release