Are object-safe associated constants possible?


It is possible to make an associated function object safe by adding where Self: Sized bound. Is there a similar trick for associated constants?

Here’s the playground which demonstrates the problem:


This appears to be a well-known limitation, perhaps temporary. There’s some discussion of this in and in this Reddit thread. The “workaround” (i.e. a pair of traits, one with an associated const and another without) is a real hack :slight_smile:.