On Sun, Jul 10, 2022 at 3:46 PM Rowan Tommins <rowan.coll...@gmail.com>
wrote:

> On 10/07/2022 13:51, Björn Larsson via internals wrote:
> > I think it's quite unlikely to deprecate such a rather big feature and
> > from that perspective I think one should do it as good as possible.
> >
> > Even if one thinks that this is a bad feature not to be expanded, why
> > not try to make it work better? So, I hope this RFC passes!
>
>
> I agree.
>
> Having sat down and read through the RFC, it is extremely conservative
> in its scope, and presents a clear case that it will fix a source of
> bugs in things that people can already do, i.e. reference constants
> inside a trait definition.
>
> It seems very unlikely that this change will make people suddenly use
> traits in more "wrong" places, nor prevent any alternative horizontal
> reuse / composition aid features being added in future.
>

I tend to agree. While I strongly dislike traits (or at least our
implementation of them), they're here to stay and we should make them less
bad where we can. Adding support for constants in traits makes sense to me,
because it removes an arbitrary limitation and inconsistency, and removes
the need for people to work around this in ways that are much worse -- for
example, by having an implicit contract between the trait and the using
class, as shown in the RFC.

Regards,
Nikita

Reply via email to