On Tuesday, 3 August 2021 at 00:54:56 UTC, Steven Schveighoffer wrote:

Given the way D works, and often template-heavy coding styles, I think it's going to be hard to do this correctly, without careful attention and lots of `version(has_xxx)` conditionals.

-Steve

I don't think optional dependencies are truly the answer.
There are ways to fix this otherwise is to break dependency chains when only a small part is used.
In this case:
- use a GC slice
- use malloc
- use std.experimental.allocator

My pet peeve is the isfreedesktop package. https://github.com/FreeSlave/isfreedesktop/blob/master/source/isfreedesktop.d package :) Yes it is annoying, but with a bit of copy-paste you can break dependencies chain and avoid the npm situation where "640 packages were installed"

Reply via email to