in reply to How we can separate a backref from a digit?

Using (?:\1) works.

Replies are listed 'Best First'.
Re^2: How we can separate a backref from a digit?
by Serge314 (Acolyte) on Mar 18, 2011 at 07:58 UTC
    It looks good. By the way:
    $a=1; print "Match\n" if "aa1" =~ /^(a)\1$a$/; # not match!
    After interpolation of variables we get the false backlink \11! To all: should I submit a bug report to perl.org?
    Serge
      Not a bug.
        It's an unexpected result.