* [PATCH] docs: rust: remove spurious item in `expect` list
@ 2024-11-17 13:31 ` Miguel Ojeda
2024-11-18 9:47 ` Alice Ryhl
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Miguel Ojeda @ 2024-11-17 13:31 UTC (permalink / raw)
To: Miguel Ojeda, Alex Gaynor
Cc: Boqun Feng, Gary Guo, Björn Roy Baron, Benno Lossin,
Andreas Hindborg, Alice Ryhl, Trevor Gross, rust-for-linux,
linux-kernel, patches
This list started as a "when to prefer `expect`" list, but at some point
during writing I changed it to a "prefer `expect` unless...` one. However,
the first bullet remained, which does not make sense anymore.
Thus remove it. In addition, fix nearby typo.
Fixes: 04866494e936 ("Documentation: rust: discuss `#[expect(...)]` in the guidelines")
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
---
Documentation/rust/coding-guidelines.rst | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/Documentation/rust/coding-guidelines.rst b/Documentation/rust/coding-guidelines.rst
index f7194f7124b0..a2e326b42410 100644
--- a/Documentation/rust/coding-guidelines.rst
+++ b/Documentation/rust/coding-guidelines.rst
@@ -296,9 +296,7 @@ may happen in several situations, e.g.:
It also increases the visibility of the remaining ``allow``\ s and reduces the
chance of misapplying one.
-Thus prefer ``except`` over ``allow`` unless:
-
-- The lint attribute is intended to be temporary, e.g. while developing.
+Thus prefer ``expect`` over ``allow`` unless:
- Conditional compilation triggers the warning in some cases but not others.
base-commit: b2603f8ac8217bc59f5c7f248ac248423b9b99cb
--
2.47.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] docs: rust: remove spurious item in `expect` list
2024-11-17 13:31 ` [PATCH] docs: rust: remove spurious item in `expect` list Miguel Ojeda
@ 2024-11-18 9:47 ` Alice Ryhl
2024-11-18 10:32 ` Andreas Hindborg
2024-11-24 23:55 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Alice Ryhl @ 2024-11-18 9:47 UTC (permalink / raw)
To: Miguel Ojeda
Cc: Alex Gaynor, Boqun Feng, Gary Guo, Björn Roy Baron,
Benno Lossin, Andreas Hindborg, Trevor Gross, rust-for-linux,
linux-kernel, patches
On Sun, Nov 17, 2024 at 2:31 PM Miguel Ojeda <ojeda@kernel.org> wrote:
>
> This list started as a "when to prefer `expect`" list, but at some point
> during writing I changed it to a "prefer `expect` unless...` one. However,
> the first bullet remained, which does not make sense anymore.
>
> Thus remove it. In addition, fix nearby typo.
>
> Fixes: 04866494e936 ("Documentation: rust: discuss `#[expect(...)]` in the guidelines")
> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Reviewed-by: Alice Ryhl <aliceryhl@google.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] docs: rust: remove spurious item in `expect` list
2024-11-17 13:31 ` [PATCH] docs: rust: remove spurious item in `expect` list Miguel Ojeda
2024-11-18 9:47 ` Alice Ryhl
@ 2024-11-18 10:32 ` Andreas Hindborg
2024-11-24 23:55 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Andreas Hindborg @ 2024-11-18 10:32 UTC (permalink / raw)
To: Miguel Ojeda
Cc: Alex Gaynor, Boqun Feng, Gary Guo, Björn Roy Baron,
Benno Lossin, Alice Ryhl, Trevor Gross, rust-for-linux,
linux-kernel, patches
"Miguel Ojeda" <ojeda@kernel.org> writes:
> This list started as a "when to prefer `expect`" list, but at some point
> during writing I changed it to a "prefer `expect` unless...` one. However,
> the first bullet remained, which does not make sense anymore.
>
> Thus remove it. In addition, fix nearby typo.
>
> Fixes: 04866494e936 ("Documentation: rust: discuss `#[expect(...)]` in the guidelines")
> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
> ---
Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org>
Best regards,
Andreas Hindborg
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] docs: rust: remove spurious item in `expect` list
2024-11-17 13:31 ` [PATCH] docs: rust: remove spurious item in `expect` list Miguel Ojeda
2024-11-18 9:47 ` Alice Ryhl
2024-11-18 10:32 ` Andreas Hindborg
@ 2024-11-24 23:55 ` Miguel Ojeda
2 siblings, 0 replies; 4+ messages in thread
From: Miguel Ojeda @ 2024-11-24 23:55 UTC (permalink / raw)
To: Miguel Ojeda
Cc: Alex Gaynor, Boqun Feng, Gary Guo, Björn Roy Baron,
Benno Lossin, Andreas Hindborg, Alice Ryhl, Trevor Gross,
rust-for-linux, linux-kernel, patches
On Sun, Nov 17, 2024 at 2:31 PM Miguel Ojeda <ojeda@kernel.org> wrote:
>
> This list started as a "when to prefer `expect`" list, but at some point
> during writing I changed it to a "prefer `expect` unless...` one. However,
> the first bullet remained, which does not make sense anymore.
>
> Thus remove it. In addition, fix nearby typo.
>
> Fixes: 04866494e936 ("Documentation: rust: discuss `#[expect(...)]` in the guidelines")
> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Applied to `rust-next` -- thanks everyone!
Cheers,
Miguel
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-11-24 23:56 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <y97yUAwS8e0qJ068FSCaq_qjGqffNgT06-DQqvuAOrx3iHV4qezwqlp9Fl9q9uOMHBgN-tGBBn4ihtDnRNFtew==@protonmail.internalid>
2024-11-17 13:31 ` [PATCH] docs: rust: remove spurious item in `expect` list Miguel Ojeda
2024-11-18 9:47 ` Alice Ryhl
2024-11-18 10:32 ` Andreas Hindborg
2024-11-24 23:55 ` Miguel Ojeda
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).