Skip to content

Commit

Permalink
Keep accepting new array elements after spread. (#216)
Browse files Browse the repository at this point in the history
  • Loading branch information
StackDoubleFlow authored and jasonwilliams committed Jan 7, 2020
1 parent 89b1249 commit 85e9a35
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/exec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ impl Executor for Interpreter {
let val = self.run(x)?;
let mut vals = self.extract_array_properties(&val).unwrap();
elements.append(&mut vals);
break; // after spread we don't accept any new arguments
continue; // Don't push array after spread
}
elements.push(self.run(elem)?);
}
Expand Down

0 comments on commit 85e9a35

Please sign in to comment.