On Mon, Jul 07, 2003 at 11:46:06AM -0700, David Storrs wrote:
> On Sat, Jul 05, 2003 at 09:06:53AM -0700, Skot wrote:
> > 
> > if ($myInputLine =~ m/.\123\.222/) { ... }
> 
> 
> Your regex consists of 6 atoms, which must be matched in the precise
> order in which they appear in order for the match to succeed.  These
> atoms are:
> 
> atom            meaning
> ----            -------
[...]
> \123            whatever was matched by the 123rd set of
>                     capturing parens earlier in this regex 
>                     [note you don't have such a thing]
[...]

My bad; I misremembered.  The atoms \1 to \9 always represent
backreferences but above 9 they are only backreferences if you
actually have that many capturing parens.  So, actually, I believe
\123 will be treated as octal character 123, which is capital S.

The reason for this up-to-9 vs after-9 split is to help the perl
parser figure out whether you wanted the backreference or the octal
character. (If you want the octal character you must give it a leading
zero, like so: \09).

--Dks

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to