Re: [PATCH 18/19] Documentation: rust: discuss `#[expect(...)]` in the guidelines

From: Trevor Gross
Date: Sun Sep 29 2024 - 01:11:17 EST


On Wed, Sep 4, 2024 at 4:45 PM Miguel Ojeda <ojeda@xxxxxxxxxx> wrote:
>
> Discuss `#[expect(...)]` in the Lints sections of the coding guidelines
> document, which is an upcoming feature in Rust 1.81.0, and explain that
> it is generally to be preferred over `allow` unless there is a reason
> not to use it (e.g. conditional compilation being involved).
>
> Signed-off-by: Miguel Ojeda <ojeda@xxxxxxxxxx>

Would it be good to mention that a reason can be specified with
`reason = "..."`? I don't think we use this anywhere yet.