Skip to content

Commit c4c5e0b

Browse files
authored
Rollup merge of #112621 - GrigorenkoPV:env, r=jyn514
Mention `env!` in `option_env!`'s docs `env!` mentions that there is an alternative that returns an `Option<...>` instead of emitting a compile error. Now `option_env!` also mentions that there is an alternative that emits a compile error instead of returning an `Option<...>`.
2 parents 9fe4630 + cfe2e46 commit c4c5e0b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

library/core/src/macros/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -960,6 +960,8 @@ pub(crate) mod builtin {
960960
///
961961
/// A compile time error is never emitted when using this macro regardless
962962
/// of whether the environment variable is present or not.
963+
/// To emit a compile error if the environment variable is not present,
964+
/// use the [`env!`] macro instead.
963965
///
964966
/// # Examples
965967
///

0 commit comments

Comments
 (0)