[Issue 4375] Require explicit braces when 'else' is ambiguous

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Jun 23 11:41:44 PDT 2010


http://d.puremagic.com/issues/show_bug.cgi?id=4375



--- Comment #3 from Jonathan M Davis <jmdavisProg at gmail.com> 2010-06-23 11:41:41 PDT ---
Ah, okay. I guess that that could be detected without regards to indentation.
As such, it probably wouldn't require huge changes to implement, and I don't
see a particular problem with it (though it does strike me as more of a warning
than an error and Walter does seem to be rather against warnings in general -
but that's a whole other debate).

Personally, I'd never run into the problem because while I often write single
statement body if-else statements and loops without braces, I always use braces
if either the condition or the body is more than one line long (even if it's a
single statement).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list