mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 13:26:01 +02:00
Fix wrong VarId of $in variable (#7893)
Fixes https://github.com/nushell/nushell/issues/7872
This commit is contained in:
@ -365,3 +365,9 @@ fn better_operator_spans() -> TestResult {
|
||||
fn range_right_exclusive() -> TestResult {
|
||||
run_test(r#"[1, 4, 5, 8, 9] | range 1..<3 | math sum"#, "9")
|
||||
}
|
||||
|
||||
/// Issue #7872
|
||||
#[test]
|
||||
fn assignment_to_in_var_no_panic() -> TestResult {
|
||||
fail_test(r#"$in = 3"#, "needs to be a mutable variable")
|
||||
}
|
||||
|
Reference in New Issue
Block a user