In article <>,
d says...
>
>Leor Zolman wrote:
>
>> (Sorry, I posted this in comp.lang.perl first before a different
>> newsreader showed me the existence of this sub-group; there seems to
>> be more activity here.)
>
>That's because comp.lang.perl is obsolete. However I replied there.
Thanks -- I'll stick to this group now
Figures, in trying to simplify the problem (which was pure r.e.'s, no "if"
statmeents), I introduced the ordering bug, which has nothing to do with my
original problem. But at least now I do know what my original problem
is. Here's a shorter version of the test program that illustrates the issue:
while (<>)
{
$pat = "\*const";
# if (/\*const/) # OK, '*' is literal
if (/$pat/) # oops, now it's a leading r.e. '*' operator!
{
print "*const\n\n"; # should match leading literal '*', no???
}
}
The trouble is that the escaped '*' is no longer escaped when I use it in the
"if", due to the use of the variable. In fact I'm building a big, fat, complex
r.e. composed of several nested variables...and the place I need to
"escape" the '*' is in one of the "inner" ones. Any way to make that work?
Thanks,
-leor
>
>--
>Kind regards, virtual home: http://johnbokma.com/ ICQ: 218175426
> web site hints: http://johnbokma.com/websitedesign/
>John I count my toes ~ one to ten ~ I meditate ~ and feel the Zen
>