You don't want to use <{…}>, you want to use ""
if $line ~~ / (^P\d+) \s+ {} "%products{$0}" / {
Note that {} is there to update $/ so that $0 works the way you would expect
Although I would do something like this instead:
my ($code,$desc) = $line.split( /\s+/, 2 );
if %products{$co
Brad: "Note that {} is there to update $/ so that $0 works the way you
would expect"
I ran into that before & was trying to remember that detail... found it in
https://docs.raku.org/language/regexes#Capture_numbers
But the example is a bit on the obtuse side:
These capture variables are only ava