in reply to Re: Using OR () in Regex
in thread Using OR () in Regex

Thats interesting - I was under the impression brackets were used as a memory more than a precedence operator... do they provide precedence in the conventional sense of the word and therefore why does this not work...

m/(\S=\S)|( =\S)|(\S= )/g

... to look for all the occurences of an equals sign that is not got whitespace on either side?

Thanks.

Replies are listed 'Best First'.
Re: Re: Re: Using OR () in Regex
by japhy (Canon) on May 06, 2002 at 12:25 UTC
    I have yet to see your code where that regex "does not work". It works for me.

    _____________________________________________________
    Jeff[japhy]Pinyan: Perl, regex, and perl hacker, who'd like a (from-home) job
    s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;