D style guide

Joseph Rushton Wakeling joseph.wakeling at webdrake.net
Mon Jun 17 11:58:45 PDT 2013


On 06/17/2013 05:48 PM, Jonathan M Davis wrote:
> What's on the website is correct. Those are all the rules that are required 
> for Phobos as a whole, and if you were creating a new module, you wouldn't 
> have had any such issues. The problem is that we try and keep the style within 
> modules consistent beyond that, and Andrei in particular is very picky about 
> that with regards to std.algorithm and std.range or any other module that he's 
> the primary author of. So, things like whether there should be a space after 
> an if (which I personally hate, but Andrei loves) or whether full-bracing is 
> required are a per-module thing. Just look at what the module you're editing 
> is doing with regards to those things when you create a pull request.

Ahh, OK.  That's fine; I don't at all mind Andrei being picky, just wanted to
check if I was missing any documentation.

The other reason was that I noticed that these local rules actually aren't
uniform even within std.random (the module in question).  I'd happily correct
that but wanted to be sure of the rules first!


More information about the Digitalmars-d-learn mailing list