summaryrefslogtreecommitdiff
path: root/src/library
diff options
context:
space:
mode:
Diffstat (limited to 'src/library')
-rw-r--r--src/library/utility.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/library/utility.rs b/src/library/utility.rs
index 3c157ea1..22bde3a1 100644
--- a/src/library/utility.rs
+++ b/src/library/utility.rs
@@ -23,8 +23,8 @@ pub fn len(_: &mut EvalContext, args: &mut FuncArgs) -> TypResult<Value> {
let Spanned { v, span } = args.expect("collection")?;
Ok(match v {
Value::Str(v) => Value::Int(v.len() as i64),
- Value::Array(v) => Value::Int(v.len() as i64),
- Value::Dict(v) => Value::Int(v.len() as i64),
+ Value::Array(v) => Value::Int(v.len()),
+ Value::Dict(v) => Value::Int(v.len()),
_ => bail!(args.source, span, "expected string, array or dictionary"),
})
}