C and memory safety comments by me
Tobias Mueller via Digitalmars-d
digitalmars-d at puremagic.com
Fri May 19 08:20:49 PDT 2017
On Friday, 19 May 2017 at 14:18:33 UTC, Jonathan M Davis wrote:
> Well, for languages like Java, C, and C++, it's mostly a result
> of folks using those languages and being unhappy with them
> (which is then often why they end up using D - it addresses a
> number of their complaints about thos languages).
I'm a (mostly) C++ programmer as my day job and I'm well aware of
its shortcomings. Still I like parts of it and I tend to get
offended by comments that make me feel like some stick-in-the-mud
idiot who still uses C++. Often it's just the tone.
And while those comments are probably not as frequent as I
suggested, they still exist and they are not opposed, so this is
what sticks.
> Another thing to keep in mind about language bashing though, is
> that the D community tends to do a lot of bashing about D. Much
> as we love D, there's a lot of complaining about various
> aspects that aren't perfect (I think in part because mant came
> to D hoping for their perfect language, and seeing it get
> really close to where you want but not quite there can be quite
> frustrating). So, it's not like the D community is constantly
> bashing other languages, claiming that D is perfect. We tend to
> bash any aspect of any language that we don't like - D included.
There's a big difference between criticizing a language (or
anything else, that is) in its own community vs in another
community.
People tend to get defensive in the latter case.
> I haven't usually seen complaints about other languages getting
> new features. The only thing along those lines that I've seen
> much of is some folks getting annoyed because C++ added a
> feature that D had had for quite a while, and the D community
> almost never gets credit for ite Now, sometimes, those ideas
> really were arrived at separately, but some are so uniquely D
> that the odds of them having not been inspired by D are _very_
> low. So, there's sometimes resentment over that. But if
> anything, the fact that that's happening just goes to show that
> D has some cool stuff that other languages might want too.
> Regardless, I don't recall anyone complaining simply because
> another language was improved in some way.
Maybe it's just me hearing things, but often those comments seem
to imply that it's worthless to add the feature to C++, because
it already exists in D and they haven't even done it right in C++.
But as a C++ programmer I welcome every feature that helps me to
write better code, I don't care where it comes from. I don't have
the choice to switch to another language.
> A _lot_ of D's featues have been inspired by other languages
> (e.g. slicing dynamic arrays and nested functions both exist in
> D, because Walter saw them in other langauges and liked them),
> and there have been plenty of occasions where another
> language's feature has been discussed for inclusion in D (e.g.
> a cleaner lambda syntax was added to D based on C#'s syntax,
> and User Defined Attributes were added, because folks had seen
> them in other languages and wanted them in D). In some
> respects, D is the poster child language of learning from other
> langauges, because so much of what we have was inspired by
> other languages or is explicitly an improvement over something
> that another langauge did (e.g. there are a lot of things in D
> that are there to learn from and improve on C, C++, Java, and
> C#).
I honestly don't know the history of D and programming languages
in general enough to judge that, but I strikes me as odd that the
main language designers know so little about their (assumed) main
competitor.
I imagine that if I would design a language, I would probably try
to understand every existing language and take the best out of
each.
Especially if another language gets a lot of attention, like Rust
currently, I'd probably want to know why and not just blame it to
hype or corporate backing.
More information about the Digitalmars-d
mailing list