mirror of
https://github.com/sagiegurari/duckscript
synced 2024-10-06 08:02:06 +00:00
Maintenance: Replace math evaluation crate to evalexpr
This commit is contained in:
parent
eed9544c79
commit
396e397e57
|
@ -1,6 +1,11 @@
|
||||||
## CHANGELOG
|
## CHANGELOG
|
||||||
|
|
||||||
### v0.8.17 (2022-01-21)
|
### v0.8.18
|
||||||
|
|
||||||
|
* Maintenance: Replace math evaluation crate to evalexpr
|
||||||
|
* Fix: fix array_contains command
|
||||||
|
|
||||||
|
### v0.8.17 (2023-01-21)
|
||||||
|
|
||||||
* Enhancement: New zip/unzip commands #294 (thanks @Red-Teapot)
|
* Enhancement: New zip/unzip commands #294 (thanks @Red-Teapot)
|
||||||
* Maintenance: Upgrade dependencies
|
* Maintenance: Upgrade dependencies
|
||||||
|
|
24
Cargo.lock
generated
24
Cargo.lock
generated
|
@ -345,6 +345,7 @@ dependencies = [
|
||||||
"cfg-if",
|
"cfg-if",
|
||||||
"colored",
|
"colored",
|
||||||
"duckscript",
|
"duckscript",
|
||||||
|
"evalexpr",
|
||||||
"fs_extra",
|
"fs_extra",
|
||||||
"fsio",
|
"fsio",
|
||||||
"glob",
|
"glob",
|
||||||
|
@ -352,7 +353,6 @@ dependencies = [
|
||||||
"home",
|
"home",
|
||||||
"ignore",
|
"ignore",
|
||||||
"java-properties",
|
"java-properties",
|
||||||
"meval",
|
|
||||||
"num_cpus",
|
"num_cpus",
|
||||||
"rand",
|
"rand",
|
||||||
"semver",
|
"semver",
|
||||||
|
@ -442,6 +442,12 @@ version = "0.1.4"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "a246d82be1c9d791c5dfde9a2bd045fc3cbba3fa2b11ad558f27d01712f00569"
|
checksum = "a246d82be1c9d791c5dfde9a2bd045fc3cbba3fa2b11ad558f27d01712f00569"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "evalexpr"
|
||||||
|
version = "9.0.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "0924058b5793a2ff91113f62c3de5e96df6d5ec0f10e213af090522fab820430"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "fastrand"
|
name = "fastrand"
|
||||||
version = "1.8.0"
|
version = "1.8.0"
|
||||||
|
@ -754,16 +760,6 @@ version = "2.5.0"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
|
checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "meval"
|
|
||||||
version = "0.2.0"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "f79496a5651c8d57cd033c5add8ca7ee4e3d5f7587a4777484640d9cb60392d9"
|
|
||||||
dependencies = [
|
|
||||||
"fnv",
|
|
||||||
"nom",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "miniz_oxide"
|
name = "miniz_oxide"
|
||||||
version = "0.6.2"
|
version = "0.6.2"
|
||||||
|
@ -791,12 +787,6 @@ dependencies = [
|
||||||
"tempfile",
|
"tempfile",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "nom"
|
|
||||||
version = "1.2.4"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "a5b8c256fd9471521bcb84c3cdba98921497f1a331cbc15b8030fc63b82050ce"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "num-integer"
|
name = "num-integer"
|
||||||
version = "0.1.45"
|
version = "0.1.45"
|
||||||
|
|
|
@ -17,7 +17,7 @@ fn test_not_found
|
||||||
assert_eq ${found} false
|
assert_eq ${found} false
|
||||||
end
|
end
|
||||||
|
|
||||||
fn test_found<F4>
|
fn test_found
|
||||||
handle = array value
|
handle = array value
|
||||||
|
|
||||||
found = array_contains ${handle} value
|
found = array_contains ${handle} value
|
||||||
|
|
6
test/std/math/calc_test.ds
Normal file
6
test/std/math/calc_test.ds
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
|
||||||
|
fn test_calc
|
||||||
|
result = calc 1 + 5 * 7
|
||||||
|
|
||||||
|
assert_eq ${result} 36
|
||||||
|
end
|
Loading…
Reference in a new issue