From 97ddb9dfa5915fe51ccabc82d79baaf70f531eed Mon Sep 17 00:00:00 2001 From: AngelicosPhosphoros Date: Tue, 2 May 2023 19:33:43 +0400 Subject: [PATCH 1/3] Add entry about `cfg!(overflow_checks)` Related to https://github.com/rust-lang/rust/pull/111096 --- src/conditional-compilation.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/conditional-compilation.md b/src/conditional-compilation.md index 97840e4f6..899b8ec77 100644 --- a/src/conditional-compilation.md +++ b/src/conditional-compilation.md @@ -222,6 +222,10 @@ This can be used to enable extra debugging code in development but not in production. For example, it controls the behavior of the standard library's [`debug_assert!`] macro. +### `overflow_checks` + +Enabled when program compiled with overflow checks enabled, e.g. in development builds. + ### `proc_macro` Set when the crate being compiled is being compiled with the `proc_macro` From 56b6225316a794d47753ad958efdcc587527223c Mon Sep 17 00:00:00 2001 From: AngelicosPhosphoros Date: Fri, 16 Jun 2023 00:29:48 +0400 Subject: [PATCH 2/3] Add info about what is overflow Co-authored-by: Eric Huss --- src/conditional-compilation.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/conditional-compilation.md b/src/conditional-compilation.md index 899b8ec77..c39564f69 100644 --- a/src/conditional-compilation.md +++ b/src/conditional-compilation.md @@ -224,7 +224,9 @@ production. For example, it controls the behavior of the standard library's ### `overflow_checks` -Enabled when program compiled with overflow checks enabled, e.g. in development builds. +Enabled when program compiled with [overflow checks] enabled, e.g. in development builds. + +[overflow checks]: expressions/operator-expr.md#overflow ### `proc_macro` From ae15da57835f4e4caa1425fe6816c1513e7ea80f Mon Sep 17 00:00:00 2001 From: AngelicosPhosphoros Date: Sat, 6 Jan 2024 17:34:29 +0100 Subject: [PATCH 3/3] Wording change Co-authored-by: Eric Huss --- src/conditional-compilation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/conditional-compilation.md b/src/conditional-compilation.md index c39564f69..93c0b7cce 100644 --- a/src/conditional-compilation.md +++ b/src/conditional-compilation.md @@ -224,7 +224,7 @@ production. For example, it controls the behavior of the standard library's ### `overflow_checks` -Enabled when program compiled with [overflow checks] enabled, e.g. in development builds. +Enabled when compiling with [overflow checks] enabled, e.g. in development builds. [overflow checks]: expressions/operator-expr.md#overflow