mirror of
https://github.com/nushell/nushell
synced 2024-11-10 07:04:13 +00:00
hopefully fixes the coercion error when comparing $nothing to $var (#3133)
This commit is contained in:
parent
c91a1ec08d
commit
983de8974b
2 changed files with 4 additions and 1 deletions
3
Cargo.lock
generated
3
Cargo.lock
generated
|
@ -2949,7 +2949,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "minus"
|
||||
version = "3.2.0"
|
||||
source = "git+https://github.com/rezural/minus?branch=add-finished-callback#b943ed5c9143924ca1f871e4911a82c2e784001a"
|
||||
source = "git+https://github.com/arijit79/minus?branch=main#eadb315644dcc051a0a3a7d4739bd59dfb37f0bd"
|
||||
dependencies = [
|
||||
"async-std",
|
||||
"crossterm 0.19.0",
|
||||
|
@ -3322,6 +3322,7 @@ dependencies = [
|
|||
"chrono-tz",
|
||||
"clap",
|
||||
"codespan-reporting",
|
||||
"crossterm 0.19.0",
|
||||
"csv",
|
||||
"ctrlc",
|
||||
"derive-new",
|
||||
|
|
|
@ -147,6 +147,8 @@ pub fn coerce_compare_primitive(
|
|||
(Date(left), Date(right)) => CompareValues::Date(*left, *right),
|
||||
(Date(left), Duration(right)) => CompareValues::DateDuration(*left, right.clone()),
|
||||
(Boolean(left), Boolean(right)) => CompareValues::Booleans(*left, *right),
|
||||
(Boolean(left), Nothing) => CompareValues::Booleans(*left, false),
|
||||
(Nothing, Boolean(right)) => CompareValues::Booleans(false, *right),
|
||||
(FilePath(left), String(right)) => {
|
||||
CompareValues::String(left.as_path().display().to_string(), right.clone())
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue