nushell/crates/nu-command/tests
Stefan Holderbach 592dc4bbfa
Fix return in filter closure eval (#12292)
# Description
Closes https://github.com/nushell/nushell/issues/12257

This was down to the use of `eval_block` instead of
`eval_block_with_early_return`. We may want to reconsider how we
differentiate between this behavior. We currently need to check all the
remaining commands that can invoke a closure block, if they properly
handle `ShellError::Return` as a passing of a `Value`

- **Add test for `return` in `filter` closure**
- **Fix use of `return` in `filter` closure**

# User-Facing Changes
You can now return a value from a `filter` closure


# Tests + Formatting
Regression test
2024-03-26 17:50:36 +01:00
..
commands Fix return in filter closure eval (#12292) 2024-03-26 17:50:36 +01:00
format_conversions Fix usage of --tabs flag while converting to json (#12115) (#12251) 2024-03-20 11:55:51 -05:00
main.rs Enforce required, optional, and rest positional arguments start with an uppercase and end with a period. (#11285) 2023-12-15 14:32:37 +08:00