/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/lazy_regex.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-12 01:41:38 UTC
  • mto: (7143.16.20 even-more-cleanups)
  • mto: This revision was merged to the branch mainline in revision 7175.
  • Revision ID: jelmer@jelmer.uk-20181112014138-3b0zyx91cu3wdq3k
More PEP8 fixes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 
19
19
This module defines a class which creates proxy objects for regex
20
20
compilation.  This allows overriding re.compile() to return lazily compiled
21
 
objects.  
 
21
objects.
22
22
 
23
23
We do this rather than just providing a new interface so that it will also
24
24
be used by existing Python modules that create regexs.
136
136
_real_re_compile = re.compile
137
137
if _real_re_compile is lazy_compile:
138
138
    raise AssertionError(
139
 
        "re.compile has already been overridden as lazy_compile, but this would"
140
 
        " cause infinite recursion")
 
139
        "re.compile has already been overridden as lazy_compile, but this "
 
140
        "would cause infinite recursion")
141
141
 
142
142
 
143
143
# Some libraries calls re.finditer which fails it if receives a LazyRegex.