Thread overview
[Issue 3699] Feature Request: while-else
Mar 19, 2014
Infiltrator
March 19, 2014
https://d.puremagic.com/issues/show_bug.cgi?id=3699


Infiltrator <lt.infiltrator@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |lt.infiltrator@gmail.com
         Resolution|                            |WONTFIX


--- Comment #7 from Infiltrator <lt.infiltrator@gmail.com> 2014-03-18 22:22:06 PDT ---
Four year old request.  Can be discussed further on NG if required.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 19, 2014
https://d.puremagic.com/issues/show_bug.cgi?id=3699



--- Comment #8 from Andrei Alexandrescu <andrei@erdani.com> 2014-03-18 23:12:04 PDT ---
Thanks for cleaning up the list!

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 19, 2014
https://d.puremagic.com/issues/show_bug.cgi?id=3699


bearophile_hugs@eml.cc changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
                 CC|                            |bearophile_hugs@eml.cc
         Resolution|WONTFIX                     |


--- Comment #9 from bearophile_hugs@eml.cc 2014-03-19 05:36:12 PDT ---
(In reply to comment #7)
> Four year old request.  Can be discussed further on NG if required.

There are bugs that sleep in bugzilla for years just because no one has time or desire to fix them, but they are still valid. I have plenty of similar bugs in bugzilla. So closing down an issue just for lack of fixes is not a good idea.

And a Python-like "else" clause of while/for/foreach is nice. You can replace code like:

bool ok = true;
foreach (...) {
    ...
    if (cond) {
        ok = false;
        break;
    }
}
if (!ok) { ... }


With:

foreach (...) {
    ...
    if (cond)
        break;
} else { ... }


Reopened until we have a true decision.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 19, 2014
https://d.puremagic.com/issues/show_bug.cgi?id=3699


Andrei Alexandrescu <andrei@erdani.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |WONTFIX


--- Comment #10 from Andrei Alexandrescu <andrei@erdani.com> 2014-03-19 08:55:27 PDT ---
I don't think we can keep all proposals opened on the off chance one may be acted upon at some point. At some point we need to make a decision.

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