We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6830574 + a5aa8b7 commit 040958cCopy full SHA for 040958c
src/path/mod.rs
@@ -163,8 +163,7 @@ impl Expression {
163
let index = sindex_to_uindex(index, array.len());
164
165
if index >= array.len() {
166
- array
167
- .resize((index + 1) as usize, Value::new(None, ValueKind::Nil));
+ array.resize(index + 1, Value::new(None, ValueKind::Nil));
168
}
169
170
Some(&mut array[index])
@@ -238,7 +237,7 @@ impl Expression {
238
237
if let ValueKind::Array(ref mut array) = parent.kind {
239
let uindex = sindex_to_uindex(index, array.len());
240
if uindex >= array.len() {
241
- array.resize((uindex + 1) as usize, Value::new(None, ValueKind::Nil));
+ array.resize(uindex + 1, Value::new(None, ValueKind::Nil));
242
243
244
array[uindex] = value;
0 commit comments