www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Documentation suggestion

reply Don Allen <donaldcallen gmail.com> writes:
Having worked with D for awhile now, after a period of love-hate 
with Rust, I'd like to make a documentation suggestion.

One of the things I like about Rust is the ability of the 
compiler to provide many helpful suggestions for keeping your 
code as uncluttered as possible. I'm talking about unused 
variable warnings, unnecessary 'use' statements, variables that 
don't need to be mutable, etc.

When first starting to work in D, I missed that. Then somehow 
(probably here) I learned about dscanner. Over a little time, 
I've found a D methodology that feels much like Rust, without all 
the annoyances and frustrations that are part of living with Rust 
and its fanboys.

As many of you do, I use DMD when developing, taking advantage of 
the compilation speed. But using dscanner has been a big help in 
cleaning up my code, ala Rust.

The website has the 'Learn' page, which I believe talks mostly 
about language features. I would suggest adding some discussion 
of things like the advantage of having the fast compiler while 
developing and another a slower compiler for use once development 
ends (if it ever does :-) that provides stronger optimization. I 
would also suggest discussion of the use of dscanner and dfmt 
(I'm really looking forward to the new one, because I'm 
constantly cleaning up after the old one's mistakes) and the 
availability of serve-d. And I would certainly mention ImportC, 
which is a significant asset.

These are all excellent aspects of D that are external to the 
language itself. I'd like to see a section of 'Learn' that talks 
about these things, pulling it all together in one place, to help 
people have a really good experience developing in D much earlier 
than I did.

I'm crazy-busy in my retirement, but if I can find the time, I 
will try to write something that I've described above. But if I 
don't get to this, someone should. Without this, D's virtues are 
being undersold.
Feb 25
parent electricface <electricface qq.com> writes:
On Sunday, 25 February 2024 at 17:25:43 UTC, Don Allen wrote:
 As many of you do, I use DMD when developing, taking advantage 
 of the compilation speed. But using dscanner has been a big 
 help in cleaning up my code, ala Rust.

 The website has the 'Learn' page, which I believe talks mostly 
 about language features. I would suggest adding some discussion 
 of things like the advantage of having the fast compiler while 
 developing and another a slower compiler for use once 
 development ends (if it ever does :-) that provides stronger 
 optimization. I would also suggest discussion of the use of 
 dscanner and dfmt (I'm really looking forward to the new one, 
 because I'm constantly cleaning up after the old one's 
 mistakes) and the availability of serve-d. And I would 
 certainly mention ImportC, which is a significant asset.

 These are all excellent aspects of D that are external to the 
 language itself. I'd like to see a section of 'Learn' that 
 talks about these things, pulling it all together in one place, 
 to help people have a really good experience developing in D 
 much earlier than I did.
Great suggestion, I support it.
Feb 26