summaryrefslogtreecommitdiff
path: root/src/eval/ops.rs
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2021-10-25 13:34:49 +0200
committerLaurenz <laurmaedje@gmail.com>2021-10-25 13:38:32 +0200
commit3968181622694c4a15ae336049439b328649bca0 (patch)
tree979093e93b49bfde47e54bc4475cedf24d12e3d8 /src/eval/ops.rs
parentadf52a873f0cdff310c236998fc5018a886b339b (diff)
Replace `..` syntax with `range` function
Diffstat (limited to 'src/eval/ops.rs')
-rw-r--r--src/eval/ops.rs8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/eval/ops.rs b/src/eval/ops.rs
index 8756e8c6..732bfb14 100644
--- a/src/eval/ops.rs
+++ b/src/eval/ops.rs
@@ -244,14 +244,6 @@ comparison!(leq, "<=", Ordering::Less | Ordering::Equal);
comparison!(gt, ">", Ordering::Greater);
comparison!(geq, ">=", Ordering::Greater | Ordering::Equal);
-/// Compute the range from `lhs` to `rhs`.
-pub fn range(lhs: Value, rhs: Value) -> StrResult<Value> {
- match (lhs, rhs) {
- (Int(a), Int(b)) => Ok(Array((a .. b).map(Int).collect())),
- (a, b) => mismatch!("cannot apply '..' to {} and {}", a, b),
- }
-}
-
/// Determine whether two values are equal.
pub fn equal(lhs: &Value, rhs: &Value) -> bool {
match (lhs, rhs) {