Phobos 3 Discussion Notes - 02-01-2024
Sebastiaan Koppe
mail at skoppe.eu
Mon Feb 5 08:20:34 UTC 2024
On Sunday, 4 February 2024 at 01:01:28 UTC, Adam Wilson wrote:
> JMD and I were talking about sockets and I think he came up
> with an interesting approach to this problem. He built a
> low-level API that is either BetterC compliant or very close to
> it, and then built a higher level API on top of that. The
> low-level API is painful to use but it allowed him to build the
> high-level API he wanted in a way that made sense. You can use
> the low-level API if you absolutely need that level of
> performance/control/etc, but most projects will find the
> high-level API to be sufficient for their needs.
>
> Perhaps this is a concept that we should investigate for other
> areas of Phobos?
Absolutely.
A lot of things in Phobos unnecessarily use classes. I feel very
strongly that V3 should go in the direction of using structs
where possible, non-copyable/scoped/unique ones if needed.
More information about the Digitalmars-d
mailing list