Re: [PATCH] rust: enable arbitrary_self_types and remove `Receiver`

From: Alice Ryhl
Date: Tue Sep 10 2024 - 08:25:59 EST


On Tue, Sep 10, 2024 at 2:09 PM Gary Guo <gary@xxxxxxxxxxx> wrote:
>
> The `arbitrary_self_types` RFC [1] is accepted and the feature is being
> worked on [2]. As part of the RFC, a new `Receiver` trait is to be added,
> and it will be automatically implemented for all types that have `Deref`
> implementation. This is different from the existing `Receiver` trait
> that we use, which is a custom implementation that opts-in a type into
> being used as receiver.
>
> To prepare us for the change, remove the `Receiver` implementation and
> the associated feature. To still allow `Arc` and others to be used as
> method receivers, turn on `arbitrary_self_types` feature instead.
>
> Cc: Adrian Taylor <ade@xxxxxxxxxxx>
> Link: https://github.com/rust-lang/rfcs/pull/3519 [1]
> Link: https://github.com/rust-lang/rust/issues/44874 [2]
> Signed-off-by: Gary Guo <gary@xxxxxxxxxxx>

Please update the commit message to explain the compatibility
situation with various rustc releases.

Alice