mirror of
https://github.com/nushell/nushell.git
synced 2025-08-10 15:58:19 +02:00
Replace &Span
with Span
since Span
is Copy
(#9770)
# Description `Span` is `Copy`, so we probably should not be passing references of `Span` around. This PR replaces all instances of `&Span` with `Span`, copying spans where necessary. # User-Facing Changes This alters some public functions to take `Span` instead of `&Span` as input. Namely, `EngineState::get_span_contents`, `nu_protocol::extract_value`, a bunch of the math commands, and `Gstat::gstat`.
This commit is contained in:
@ -22,6 +22,6 @@ impl Plugin for GStat {
|
||||
|
||||
let repo_path: Option<Spanned<String>> = call.opt(0)?;
|
||||
// eprintln!("input value: {:#?}", &input);
|
||||
self.gstat(input, repo_path, &call.head)
|
||||
self.gstat(input, repo_path, call.head)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user