Emanuele D'Arrigo wrote:
[snip]
If the answer is no, am I right to state the in the case portrayed
above the only way to be safe is to use the following code instead?

for item in compiledPatterns:
   if(item.pattern == pattern):
        print("The compiled pattern is stored.")
        break

Correction to my last post: this isn't the same as using 'in'.

It should work, but remember that it compares only the pattern and not
any flags you might have used in the original re.compile().

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to