Back in D after some absence, some perspective

H. S. Teoh hsteoh at quickfur.ath.cx
Tue Mar 2 22:11:37 UTC 2021


On Tue, Mar 02, 2021 at 09:05:14PM +0000, deadalnix via Digitalmars-d wrote:
[...]
> As you might know, I was very active a couple of years ago and then
> got driven away, mostly by work, family and so on. But I've been back
> for a couple of month now and I thought I'd write a little about what
> changed on larger time scale. It is not always easy to see this when
> being in D on a day to day basis, so I thought this would be valuable
> feedback for everybody.

Very valuable indeed!


> The bad:
> I ran into many bugs still, mostly in phobos.
[...]
> In any case, a common pattern across several of these bugs was a poor
> handling of the "empty" case.
[...]
> That should probably be added to the checklist of test case to have
> for something to be considered mergeable. Not sure it is automatable,
> but human can use their judgement to get it sorted out.

I think there should be an official checklist of test cases that need to
be covered before a PR is merged.  Of course it can't be a precise
checklist because every PR is different, but without an official,
written guideline, it's too easy to just forget about this or that
corner case and unknowingly introduce bugs.


> Another major pain point was dub. It is wonderful to get something up
> and running quickly, but then turn into a nightmare when it come to
> packaging and distribution. The root cause seems to be that dub tries
> to be too many things at once, such as a dependency manager and a
> build system.

I've been staying away from dub precisely because of the above
architectural issues, but telling people to stay away is not a viable
solution.  I don't know how to solve this problem without completely
redesigning dub, though.  It's too entrenched to change now, and we
don't want to lose the ecosystem that has been painstakingly built up
around it.


> The good:
> No more ICE! At least I haven't run into any so far.

Yay!


> The awesome:
> The support I got through all of this was first class. I don't know if
> this is because it's me and people know me or if this is general, but
> it is way better than a couple of years ago and bugs gets fixed way
> faster.

I think now that the foundation has hired a couple of people to handle
the mundane, day-to-day chores, there's been more grease in the gears
and things are running a little more smoothly now. Hopefully this will
continue into the future.


[...]
> D has reached a point where it needs to heavily focus on its
> toolchain, as well as ensuring the soundness of what's there, nailing
> small inconsistencies, etc...

Yeah, the small inconsistencies really need to be fixed. They may be
small, minor details from a language perspective, but these minor
details cause a domino effect of weird corner cases that cause pain down
the road, esp. to newcomers unfamiliar with the gotchas involved. These
corner cases really need to be smoothed out.

Also, to mention another (relatively) recent awesome development: LDC
has been supporting almost out-of-the-box cross-compilation from Linux
to Windows, and I've been really enjoying that. All it takes now is just
to download and unpack LDC for Linux and LDC for Windows, then add a
block to the config file, and it's all set for heavy-duty
cross-compilation.

Also, if you ever need to interface with Java, check out Adam's jni.d.
Metaprogramming awesomeness that makes it so easy to interface D with
Java, I'm actually starting to lose some of my dislike for Java. :-D


T

-- 
Why waste time learning, when ignorance is instantaneous? -- Hobbes, from Calvin & Hobbes


More information about the Digitalmars-d mailing list