Kirk Haines <khaines / enigo.com> wrote:
 
> The only idea that I have come up with is to put the literal matches in a 
> hash, and then have the regular expressions in an array.  If there isn't a 
> literal match, then one has to accept the time consuming process of 
> iterating through each regexp and checking it.  Can anyone think of any 
> other approaches that might be faster?

If you only need to know that there is a match, rather than what
matched, how about combining all the regexps into one big regexp using
((re1)|(re2)|...)?

martin