Re: [vox-tech] some excercise for you linux geek.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [vox-tech] some excercise for you linux geek.
On Thu, Dec 07, 2000 at 04:48:10PM -0800, Mark Kim wrote:
> On Thu, 7 Dec 2000, Micah Cowan wrote:
>
> > The backslashed-escaped characters {, }, (, and ) would all lose their
> > special meanings in a regex.
>
> Actually, it depends on the regex interpreter. As I recall, in PERL, you
> use (...) to represent a group of characters that need to be remembered
> for later recalling. Under sed, \(...\) is used to do the same. (Perl
> also uses $1 instead of \1 for recalling, doesn't it?)
Both, actually, but $1 is preferred (because anything higher than \9 won't
work)
>
> If you don't put the backslashes in front of ( or ), you match the
> parenthesis characters, I think. The same *seems* to be true for curly
> braces... on Sed, anyway.
Ah, I see. In Perl it's the reverse.
>
> -Mark (still a trial-and-error regex user...)
>
|