Why is `opequals` for objects not `@safe` by default?
Alexandru Ermicioi
alexandru.ermicioi at gmail.com
Sun Apr 7 16:51:27 UTC 2024
On Friday, 5 April 2024 at 16:02:27 UTC, H. S. Teoh wrote:
> We've been talking about ProtoObject for years now. When will
> that materialize?
Why do even need proto object?
Can't we just have a bunch of interfaces for each kind of
operator and attribute set?
For example:
```d
interface Equatable(Attrs...) {
bool opEquals(Equatable!Attrs other);
}
// and etc.
```
Those interfaces could perfectly work as object roots, when
required, and no need for having an actual class as root for all
objects.
Best regards,
Alexandru.
More information about the Digitalmars-d
mailing list