Skip to content

Commit 5c63506

Browse files
authored
Rollup merge of #87395 - ericonr:patch-1, r=joshtriplett
Clear up std::env::set_var panic section. The "K" parameter was being referred to as "key", which wasn't introduced anywhere.
2 parents c673d3f + 74f01a4 commit 5c63506

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

library/std/src/env.rs

+3-4
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ impl Error for VarError {
294294
}
295295
}
296296

297-
/// Sets the environment variable `k` to the value `v` for the currently running
297+
/// Sets the environment variable `key` to the value `value` for the currently running
298298
/// process.
299299
///
300300
/// Note that while concurrent access to environment variables is safe in Rust,
@@ -310,9 +310,8 @@ impl Error for VarError {
310310
///
311311
/// # Panics
312312
///
313-
/// This function may panic if `key` is empty, contains an ASCII equals sign
314-
/// `'='` or the NUL character `'\0'`, or when the value contains the NUL
315-
/// character.
313+
/// This function may panic if `key` is empty, contains an ASCII equals sign `'='`
314+
/// or the NUL character `'\0'`, or when `value` contains the NUL character.
316315
///
317316
/// # Examples
318317
///

0 commit comments

Comments
 (0)