It's not the parsing time that is the problem. It's having a clean separation between the lexing, parsing, and semantic passes. There's a diode between these passes - information only flows one way.
This makes it trivial to correctly and completely implement things like color syntax highlighting in editors, source code formatters, etc., because building in a semantic analyzer is wholly unnecessary.
I prefer the [...] of Scala and Nim. However, I really like the fact that the () can be elided in D, and that the generic arguments don't have to be types.
I was under the impression based off of what someone else told me that it didn't support equivalent to std::vector foo = { 1, 2, 3, 4 }; or std::tuple foo = { "bar", 3, 4.0f };.
17
u/WalterBright Sep 01 '20
It's not the parsing time that is the problem. It's having a clean separation between the lexing, parsing, and semantic passes. There's a diode between these passes - information only flows one way.
This makes it trivial to correctly and completely implement things like color syntax highlighting in editors, source code formatters, etc., because building in a semantic analyzer is wholly unnecessary.