# New Ticket Created by Aaron Sherman # Please include the string: [perl #69552] # in the subject line of all future correspondence about this issue. # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=69552 >
When .subst has a void or Bool context, it should issue a warning, since there is no logical reason to perform such an action (in a Bool context, it's just being used to perform a match, for which a match should be used, not a substitution). This will avoid the confusion embodied in this test program: my $s = "abc"; while $s.subst(regex { <+lower> }, '') { print ~$/ } which one might expect to print "abc", but instead prints an infinite sequence of "aaaa..." becuase it performs substitution on a copy, not in-place.