fix: panic of if command as a constant expr by bringing back Type::Block (#16122)

Fixes #16110. Alternative to #16120 

# Description

# User-Facing Changes

no more panic

# Tests + Formatting

+1

# After Submitting
This commit is contained in:
zc he
2025-07-08 20:45:35 +08:00
committed by GitHub
parent a674ce2dbc
commit 4da755895d
8 changed files with 24 additions and 7 deletions

View File

@ -353,6 +353,7 @@ fn nu_value_to_sqlite_type(val: &Value) -> Result<&'static str, ShellError> {
// intentionally enumerated so that any future types get handled
Type::Any
| Type::Block
| Type::CellPath
| Type::Closure
| Type::Custom(_)