News for hackers. Stuff that matters.
Re:A working D compiler on OpenBSD by bogwog on Sunday March 21, 2021 @08:10PM (#26535337)
Is D's value proposition that it's a better successor of C than C++? Because that's what it seems like to me from a quick read of the website.

But it also seems like D is not suitable for a lot of things that C++ is, like embedded applications. Also, it doesn't seem like support for Android and iOS is very good at the moment. So for portability, C++ is still the only choice.

D does seem really nice though, like a modern high level language, but with support for custom memory management, low-level system APIs, and even ABI compatibility with C. But I'm hesitant to build anything with it because as much as I loathe working in C++, it's still the safest bet by far.

Also, Swift seems like it has similar goals, but with Apple's full support behind it.

Re:A working D compiler on OpenBSD by EvenThisAcronym on Monday March 22, 2021 @07:51AM (#26539541)
> But it also seems like D is not suitable for a lot of things that C++ is, like embedded applications

Not sure where you got this idea, as being usable for embedded programming is explicitly one of D's design goals. You can use D anywhere you use C++, and it is a much nicer language to boot!

> Also, it doesn't seem like support for Android and iOS is very good at the moment

I can't comment on this. There is support for both platforms IIRC, but I haven't tried writing apps for either in D.

> But I'm hesitant to build anything with it because as much as I loathe working in C++, it's still the safest bet by far.

I'm not sure what you mean by "safe" here. D has been around for over 20 years and isn't going anywhere anytime soon. The main difference from C++ is that the community is smaller, and it's a bit harder to get a job writing D (but not that much harder nowadays; there are a lot of people working for companies like Symmetry Investments, writing D every day).

> Also, Swift seems like it has similar goals, but with Apple's full support behind it.

Swift also seems like a very nice language, and I would probably be using it if D didn't exist. That being said, its metaprogramming capabilities are woefully underpowered to D's. From my experience, only the Lisp family of languages beat D in this area.