update to rust version 1.87.0 (#16437)

The PR upgrades nushell to rust version 1.87.0.

## Dev overview from clippy
- I added `result_large_err` to clippy in the root Cargo.toml to avoid
the warnings (and a few places in plugins). At some point a more proper
fix, perhaps boxing these, will need to be performed. This PR is to just
get us over the hump.
- I boxed a couple areas in some commands
- I changed `rdr.bytes()` to `BufReader::new(rdr).bytes()` in nu-json

## Release notes summary - What our users need to know
Users can use rust version 1.87.0 to compile nushell now

## Tasks after submitting
N/A
This commit is contained in:
Darren Schroeder
2025-08-14 11:27:34 -05:00
committed by GitHub
parent daf52ba5c8
commit 36427a7434
11 changed files with 25 additions and 20 deletions

View File

@@ -2,16 +2,16 @@
//!
//! This module provides for Hjson deserialization with the type `Deserializer`.
use std::char;
use std::io;
use std::marker::PhantomData;
use std::str;
use serde::de;
use super::error::{Error, ErrorCode, Result};
use super::util::StringReader;
use super::util::{Number, ParseNumber};
use serde::de;
use std::{
char, io,
io::{BufReader, Read},
marker::PhantomData,
str,
};
enum State {
Normal,
@@ -804,7 +804,10 @@ where
R: io::Read,
T: de::DeserializeOwned,
{
from_iter(rdr.bytes())
// Use a buffered reader so that calling `.bytes()` is efficient and
// doesn't trigger clippy's `unbuffered_bytes` lint when the input
// comes from a non-memory source.
from_iter(BufReader::new(rdr).bytes())
}
/// Decodes a Hjson value from a byte slice `&[u8]`.