mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 14:36:08 +02:00
Fix for loop ctrlc not terminating (#5003)
This commit is contained in:
@ -125,7 +125,7 @@ https://www.nushell.sh/book/thinking_in_nushell.html#parsing-and-evaluation-are-
|
||||
.filter(|x| !x.is_nothing())
|
||||
.into_pipeline_data(ctrlc)),
|
||||
Value::Range { val, .. } => Ok(val
|
||||
.into_range_iter()?
|
||||
.into_range_iter(ctrlc.clone())?
|
||||
.enumerate()
|
||||
.map(move |(idx, x)| {
|
||||
stack.with_env(&orig_env_vars, &orig_env_hidden);
|
||||
|
@ -71,7 +71,7 @@ impl Command for ParEach {
|
||||
|
||||
match input {
|
||||
PipelineData::Value(Value::Range { val, .. }, ..) => Ok(val
|
||||
.into_range_iter()?
|
||||
.into_range_iter(ctrlc.clone())?
|
||||
.enumerate()
|
||||
.par_bridge()
|
||||
.map(move |(idx, x)| {
|
||||
|
@ -81,7 +81,7 @@ pub fn calculate(
|
||||
}
|
||||
PipelineData::Value(Value::Range { val, .. }, ..) => {
|
||||
let new_vals: Result<Vec<Value>, ShellError> = val
|
||||
.into_range_iter()?
|
||||
.into_range_iter(None)?
|
||||
.map(|val| mf(&[val], &name))
|
||||
.collect();
|
||||
|
||||
|
Reference in New Issue
Block a user