[Python-Dev] Speeding up regular expression compilation
Martin v. Löwis
martin at v.loewis.de
Thu Oct 30 17:16:48 EST 2003
More information about the Python-Dev mailing list
Thu Oct 30 17:16:48 EST 2003
- Previous message: [Python-Dev] Speeding up regular expression compilation
- Next message: [Python-Dev] HTML parsing: anyone use formatter?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Bram Moolenaar <Bram at moolenaar.net> writes: > Is there a trick to make compiling patterns go faster? If you compile the same regular expression at every program startup, and want to reduce the time for that, you can cPickle the compile expression, and restore it from the string. If that fails (because the format of compiled expressions has failed), you should fall back to compiling expressions, and optionally save the new version. Regards, Martin
- Previous message: [Python-Dev] Speeding up regular expression compilation
- Next message: [Python-Dev] HTML parsing: anyone use formatter?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-Dev mailing list