Replies: 5 comments 6 replies
-
Parts of the D standard library require a garbage collector. Carbon and C++ do not require GC, and do not normally use a GC. That seems like a big difference. It's going to be an important issue for anyone who does not want a GC in their runtime. In D, you can compile with @nogc, and get compile errors when your code or its dependencies uses something that requires GC. This seems worse than not having to worry about the issue at all. Clearly, if you want GC then D is a better choice than Carbon. But that's not who Carbon is being designed for. |
Beta Was this translation helpful? Give feedback.
-
Carbon can directly include C++ header files. D can't do this, and it is not a goal. Quote:
|
Beta Was this translation helpful? Give feedback.
-
I would change that to "why not a fork/improvements of D?". D has unmatched nice syntax base and templates/CTFE system but its developers seem to have 0 interest in making it usable beyond the system programming. Reusing things that already work perfect and reimplementing questionable parts seems to be better option than making it from scratch and being worse. Especially when D already had prototypes in that field - |
Beta Was this translation helpful? Give feedback.
-
I've filed #1875 to add an FAQ entry for this. |
Beta Was this translation helpful? Give feedback.
-
As far as I can tell, Carbon's goals are pretty much compatible with D, as Walter Bright pointed out as soon as Carbon was posted to Hacker News.
I suspect this must have been discussed, so it would be nice to have "Why not D" entry in FAQ, in addition to existing "Why not Rust" entry. I must not be the only one to be curious.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions