D benchmark code review

Brian Rogoff brogoff at gmail.com
Sat Dec 14 12:00:29 PST 2013


On Saturday, 14 December 2013 at 19:32:45 UTC, Chris Cain wrote:
> On Saturday, 14 December 2013 at 16:22:41 UTC, Ola Fosheim 
> Grøstad wrote:
>> Regarding using the not-operator for non-not-operations: 
>> anything would be better than reusing operators that are 
>> commonly used to affect control-flow. It makes it difficult to 
>> comprehend control flow when you skim code you are not 
>> familiar with. "not" tends to be used for completely changing 
>> the flow of a program so those "!" are attention-seekers when 
>> trying comprehend unfamiliar code.
>
> But still, _what exactly_ should be used instead of the 
> "not-operator"? "Anything" is too vague and not true. You 
> probably can't use these: ][+=-_,.|`\/"'><;:}{%^&*

Composite brackets, a-la the SPECS 'C++ Resyntaxed' ** proposal, 
would work. <[]>, <[<[]>]> may be a bit heavy but not too bad.

I haven't found the !() syntax for D templates to be a problem 
though and prefer it to <> from C++ and Java. If I were searching 
for D blemishes, I wouldn't look there first.

-- Brian

** 
http://www.csse.monash.edu.au/~damian/papers/HTML/ModestProposal.html


More information about the Digitalmars-d mailing list