in reply to Parenthesis grouping into regexes.

my $prefix = "/\d\d";
Here's your problem. You're using \d in double quoted context. $prefix is just /dd. use warnings would have told you so. Printing $prefix would have told you as well.

Replies are listed 'Best First'.
Re^2: Parenthesis grouping into regexes.
by aramisf (Beadle) on Apr 26, 2012 at 18:25 UTC
    Yes, you're right. I modified that, but the problem persisted.
    I'll comment below...