mirror of
https://github.com/nushell/nushell.git
synced 2024-11-28 03:13:44 +01:00
Fix compilation for nu_protocol::value::from_value
on 32-bit targets (#13169)
# Description Needed to cast `usize::MAX` to `i64` for it to compile properly cc @cptpiepmatz
This commit is contained in:
parent
b79a2255d2
commit
97876fb0b4
@ -301,7 +301,7 @@ impl_from_value_for_uint!(u64, i64::MAX); // u64::Max would be -1 as i64
|
|||||||
#[cfg(target_pointer_width = "64")]
|
#[cfg(target_pointer_width = "64")]
|
||||||
impl_from_value_for_uint!(usize, i64::MAX);
|
impl_from_value_for_uint!(usize, i64::MAX);
|
||||||
#[cfg(target_pointer_width = "32")]
|
#[cfg(target_pointer_width = "32")]
|
||||||
impl_from_value_for_uint!(usize, usize::MAX);
|
impl_from_value_for_uint!(usize, usize::MAX as i64);
|
||||||
|
|
||||||
impl FromValue for () {
|
impl FromValue for () {
|
||||||
fn from_value(v: Value) -> Result<Self, ShellError> {
|
fn from_value(v: Value) -> Result<Self, ShellError> {
|
||||||
|
Loading…
Reference in New Issue
Block a user