[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANiq72=BAZPc94pa9LLYnuYMcxi-cWnKSZAOTGhJOWRv4FGXug@mail.gmail.com>
Date: Tue, 20 Jun 2023 19:55:30 +0200
From: Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
To: Alice Ryhl <alice@...l.io>, Gary Guo <gary@...yguo.net>
Cc: Jakub Kicinski <kuba@...nel.org>, Andrew Lunn <andrew@...n.ch>,
FUJITA Tomonori <fujita.tomonori@...il.com>, netdev@...r.kernel.org,
rust-for-linux@...r.kernel.org, aliceryhl@...gle.com
Subject: Re: [PATCH 0/5] Rust abstractions for network device drivers
On Tue, Jun 20, 2023 at 7:44 PM Miguel Ojeda
<miguel.ojeda.sandonis@...il.com> wrote:
>
> Yeah, and we could use `build_assert!(false);` to ensure we don't ever
> call it (by users, or by the the custom destructor methods) -- it
i.e. `build_assert!` is a similar trick we have to produce a linker
error like Alice suggested. It was "nicely packaged" by Gary a while
ago :)
Actually, it should be `build_error!("Normal destructor should never
be called");` -- same thing (I just forgot we had that one).
Cheers,
Miguel
Powered by blists - more mailing lists