nushell/crates/nu-engine/src/lib.rs
Horasal 54394fe9af
Allow operator in constants (#10212)
This pr fixes https://github.com/nushell/nushell/issues/10200

# Description

Allow unary and binary operators in constants, e.g.

```bash
const a = 1 + 2
const b = [0, 1, 2, 3] ++ [4]
```

# User-Facing Changes

Now constants can contain operators.

# Tests + Formatting

- 🟢 `toolkit fmt`
- 🟢 `toolkit clippy`
- 🟢 `toolkit test`
- 🟢 `toolkit test stdlib`

# After Submitting

None

---------

Co-authored-by: Horasal <horsal@horsal.dev>
2023-09-05 16:35:58 +02:00

18 lines
421 B
Rust

mod call_ext;
pub mod column;
pub mod documentation;
pub mod env;
mod eval;
mod glob_from;
pub mod scope;
pub use call_ext::CallExt;
pub use column::get_columns;
pub use documentation::get_full_help;
pub use env::*;
pub use eval::{
eval_block, eval_block_with_early_return, eval_call, eval_expression,
eval_expression_with_input, eval_subexpression, eval_variable, redirect_env,
};
pub use glob_from::glob_from;