Interesting user mistake

H. S. Teoh via Digitalmars-d digitalmars-d at puremagic.com
Fri Sep 4 13:41:11 PDT 2015


On Fri, Sep 04, 2015 at 10:41:05PM +0200, Andrej Mitrovic via Digitalmars-d wrote:
> On 9/3/15, Andrei Alexandrescu via Digitalmars-d
> <digitalmars-d at puremagic.com> wrote:
> > http://stackoverflow.com/questions/32369114/leap-years-not-working-in-date-and-time-program-in-dlang
> >
> > The gist of it is the user wrote =+ instead of +=. I wonder if we
> > should disallow during tokenization the sequence "=", "+",
> > whitespace. Surely it's not a formatting anyone would aim for, but
> > instead a misspelling of +=.
> 
> The gist of it is that it's interesting because it's such a rare
> occurrence. That's why we probably shouldn't even think about it. I've
> never seen such mistakes in OSS code before, and I've never seen it in
> production code either. It's so rare that we shouldn't spend any time
> thinking about it.
> 
> Sure it's interesting, but why bother with this special case when
> there's bigger fish to fry?

https://en.wikipedia.org/wiki/Parkinson%27s_law_of_triviality

:-)


T

-- 
"I'm not childish; I'm just in touch with the child within!" - RL


More information about the Digitalmars-d mailing list