On Wed, Aug 28, 2013 at 4:19 PM, Zefram <zefram@fysh.org> wrote: > via RT wrote: > >My proposal: > > Since we can label any statement (now), why not have the reset operator > take a label argument? > > I think the toggle operator is a wart that we should lean towards > removing, not something to encourage wider use of. Use of global vars/states keeps getting us into trouble. This would be easy to implement using Devel::CallParser: my $toggle; while (...) { if (flipflop($toggle, EXPR1, EXPR2)) { ... } } It's not much more complicated than the existing syntax, and it could allow C<next> and such to work (unlike a sub(&) approach).Thread Previous | Thread Next