Why I Like D
81–90 of 134 posts
Re: Why I Like D
#82That's what she said! On a more serious note it's cool to see the languages creator quite frequently on HN - it is the reason I took a look at it a while ago :)
The D test suite takes too long to run, so I wind up here.
Re: Why I Like D
#83Earlier quoted context omitted.
Someone else made a really good point about hype today: 'One of the dumbest lessons I’ve learned in my career is that you should never disregard something that has hype behind it, even if you don’t think the tech makes sense. [0] Most “tech adoption” problems are really human coordination problems. Hype solves those. It doesn’t matter if you have a better solution, or that you think the proposed solution is stupid. […
> you should never disregard something that has hype behind it Do you have an opinion on how this sentiment applies to blockchain tech? I’m not trolling, I think the sentiment is interesting and blockchain tech seems obviously relevant to that sentiment.
Re: Why I Like D
#84But, I think one of the things that people seemed very happy about feature-wise that started to turn me off the language was UFCS. I don't deny that it makes the written code look more elegant but I think to me it existed as a net negative for other people who are unfamiliar with the code they are reading. There was an example someone gave years ago on reddit that was supposed to convey how clean the code to solve the problem was but it included an UFCS expression of the form 'a.b!c.d' which was sans-UFCS 'd(b!c(a))'. Trying to determine which reordering the compile would going to eventually choose seemed like more work than should be necessary for simple expression like that.
Having said all that it still might be a good choice for certain development environments and I should see whether there's a second edition of TDPL.
Re: Why I Like D
#85I started learning D in 2012 and will echo that Andrei's book is great, and imo one of the most entertaining and informational technical books I've read. The D forum was a great example of dogfooding and the people seemed nice when I would post things. But, I think one of the things that people seemed very happy about feature-wise that started to turn me off the language was UFCS. I don't deny that it makes the writt…
It helps keep structs small and simple, rather than becoming kitchen sinks.
Re: Why I Like D
#86Are there linters and other static analysis tools for D?
Re: Why I Like D
#87Earlier quoted context omitted.
Still wondering why don't people like D more after all these years it's been there.
Probabaly lack of killer application. If you released super popular whatever (game engine, embedded platform, 3d design software) that uses D as its customization language suddenly a lot more people would have a good reason to learn D.
Re: Why I Like D
#88Earlier quoted context omitted.
The library looks impressive, but I dunno about that sales pitch: isn't "more principled than C++ templates"… a pretty low bar? And isn't "more practical than Template Haskell"… also a pretty low bar? I would have asked the same rhetorical question of Scala macros a couple years back, but the Scala 3 macro redesign is indeed pretty nice.
While the design D picked for templates looks (and is) straightforward, it wasn't obvious. It's only obvious in retrospect (which is something a good design aspires to, like putting an eraser on the other end of the pencil).
My point isn't that "D doesn't meet that bar", but that the GP picked strange points of comparison: the steelman argument for C++ templates would focus on power (e.g. Eigen) instead of principles, and those for Template Haskell on safety instead of practicality. And of course, no macro comparison would be complete without gesturing vaguely in the direction of Lisp while muttering something about parentheses.
It's like the "Always Be Closing" speech in Glengarry Glen Ross: Dlang macros as John Travolta truly do kick ass in that scene—but why not have Al Pacino there to represent as top dog of the local branch?
Re: Why I Like D
#89I started learning D in 2012 and will echo that Andrei's book is great, and imo one of the most entertaining and informational technical books I've read. The D forum was a great example of dogfooding and the people seemed nice when I would post things. But, I think one of the things that people seemed very happy about feature-wise that started to turn me off the language was UFCS. I don't deny that it makes the writt…
UFCS is one of the most popular features. It's utility is in extending the functionality of a struct without adding member functions that would get private access, but don't need private access. It helps keep structs small and simple, rather than becoming kitchen sinks.
Without knowing any of the associated types and members how many interpretations could the prior expression 'a.b!c.d' have with UFCS and parens-less calling conventions (and any other feature that might contribute to different semantics)?
b!(c.d)(a)
b!(d(c))(a)
d(b!c(a))
d(a.b!c)
Might be more? Don't get me wrong I see the benefit. The vectorflow example I think is a good use case thought because it allows a more natural conceptualization of object -> member access -> conversion rather than having to call to!ulong(W.length) which forces the reader to start with the (pending) conversion. You get this same dataflow/conceptualization benefit in threading macros in clojure (->, ->>, etc).Anyway, thank you for all the work you've done.
Re: Why I Like D
#90Earlier quoted context omitted.
Partial aside, BetterC sounds a lot like Zig and Andrew Kelley moved to Oregon a year or two ago. Have you talked with Andrew? Funny that two of the language creators in the space are so close to each other on Earth. I'd love to listen to you two discuss D, BetterC and Zig and C.
I met him at Handmade Seattle last Nov. He's a good guy.