# New Ticket Created by  "Carl Mäsak" 
# Please include the string:  [perl #124247]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=124247 >


$ perl6 -v
This is perl6 version 2015.03-170-g143f621 built on MoarVM version
2015.03-49-gce786a1

$ perl6 -e '$_ = "5 breads and 2 fish"; s[(\d)] = "{$0 * 10}"; .say'
50 breads and 2 fish

$ cat input
5 breads and 2 fish
$ perl6 -pe 's[(\d)] = "{$0 * 10}"' < input
use of uninitialized value of type Nil in numeric context  in block
<unit> at -e:1

0 breads and 2 fish

Expectation: that `s[(\d)] = "{$0 * 10}"` statement shouldn't give a
warning about $0 being Nil, just because I'm in -p

Reply via email to