diff options
| author | Laurenz <laurmaedje@gmail.com> | 2021-07-29 12:21:55 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2021-07-29 12:28:54 +0200 |
| commit | 7d15dc634b3be1b6e284bb6b2450e3736d3e6e8d (patch) | |
| tree | f1dc308528515ccfc90e047fe3cb75bd171b3f8c /src/library/utility.rs | |
| parent | 853361338bd756c23992041511b1836a2cd0647f (diff) | |
Move font family and refactor alignment
Diffstat (limited to 'src/library/utility.rs')
| -rw-r--r-- | src/library/utility.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/library/utility.rs b/src/library/utility.rs index ce45aae7..4001d14f 100644 --- a/src/library/utility.rs +++ b/src/library/utility.rs @@ -24,7 +24,7 @@ pub fn repr(ctx: &mut EvalContext, args: &mut FuncArgs) -> Value { /// `len`: The length of a string, an array or a dictionary. pub fn len(ctx: &mut EvalContext, args: &mut FuncArgs) -> Value { - match args.expect::<Spanned<Value>>(ctx, "collection") { + match args.expect(ctx, "collection") { Some(Spanned { v: Value::Str(v), .. }) => Value::Int(v.len() as i64), Some(Spanned { v: Value::Array(v), .. }) => Value::Int(v.len() as i64), Some(Spanned { v: Value::Dict(v), .. }) => Value::Int(v.len() as i64), |
