3 ms·
> Consider C's Biggest Mistake I do not think it is a significant problem in C. It might be more of a problem in C++. > You can use D in -betterC mode, write
by x0re4x 7y ago
> Consider C's Biggest Mistake
I do not think it is a significant problem in C. It might be more of a problem in C++.
> You can use D in -betterC mode, write code pretty much just like you would in C, and not have that problem.
D is an improved, more polished version of _C++_, not C; "-betterC" mode is misleading, it is more of a "betterC++" mode (features: classes, exceptions, RAII, templates).
"The simplicity of C is more useful than the additional features of C++." -- (Sam Watkins) s/C++/D/g
Don't get me wrong: D would be a great replacement for _C++_, but not C. For a better C I would look at a subset of Go (GC would have to go away).
- WalterBright 7y agoD in "betterC" mode does not have GC, classes, exceptions, or RTTI. Nor does it need the D (or C) runtime library. (It does have RAII without using exceptions.)
- x0re4x 7y agoThank you for clarification. I was looking at https://www.digitalmars.com/articles/betterC.html https://www.digitalmars.com/articles/betterC.html, https://dlang.org/spec/betterc.html https://dlang.org/spec/betterc.html is a better description.