tlhackque wrote: >>One might imagine a toggle object as a middle ground -- e.g. >> $toggle = Toggle::new( '...', sub {/^--a$/} , sub {/^--b$/}); # Can be done much more neatly by a call-checker plugin and custom ops. I'm thinking of it looking something like $out .= $_ if toggle /^--a$/, /^--b$/; Named toggles just need a slight extension to put their state somewhere visible. As the hiddenness of a toggle's state is a nasty aspect of the core feature, I'd be inclined to make these toggles use an explicit variable, whose lifetime can be controlled in the usual ways: my $tog; reset_toggle $tog; $out .= $_ if toggle $tog, /^--a$/, /^--b$/; >>such as >> >> reset ['label']; or reset( ['label'], 2 ); If a toggle reset feature is added to the core, it should not further overload an existing core operator, especially one that is presently unrelated. -zeframThread Previous | Thread Next