2 ms·
Here's what happens (the same thing happened with Ddoc, the documentation generator build in to the compiler). Before Ddoc, there were documentation generators
by WalterBright 6y ago
Here's what happens (the same thing happened with Ddoc, the documentation generator build in to the compiler).
Before Ddoc, there were documentation generators like DOxygen, a third party tool. Doxygen was a fine documentation generator, with lots of great features. The trouble was, it was a third party tool:
1. There were other documentation generators, all different.
2. People would install D, and not have a documentation generator. They'd have to do research, pick one, and install it.
3. The third party tool may not work that well with D.
4. The third party tool may be out of sync with the version of D that the user is doing.
5. The third party tool always comes with a large and intimidating manual.
The end result was, maybe 1% of D users used a documentation generator. 10% wrote documentation as a separate file. 89% just wrote zero documentation at all.
Even worse, the 10% documentation rarely matched what the function actually did. In fact, sometimes it was unrecognizable.
This was the state of, for example, the D runtime library documentation. All of it was either totally wrong, out of date, or missing entirely.
Enter Ddoc. Yes, Ddoc is inferior to DOxygen. But every D user now has a documentation already installed, and a perfect match for the version of D they have. Now writing documentation becomes trivial, as Ddoc can read the function headers. When one modifies the function, it's trivial to fix the documentation, as it's right there. When submitting a pull request, the reviewer goes "where's the documentation".
The result was a night and day difference. Suddenly the Phobos documentation was all there, and accurate.
The same effect happened with builtin unittests. Sure, D's builtin unittest framework isn't as good as advanced third party testing frameworks. But it's always there, and always works, and the difference in results is stunning. Take a look at the Phobos source code - half of it is unittests.