diff options
author | Bruno Haible <bruno@clisp.org> | 2022-08-05 04:05:04 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2022-08-05 15:06:21 +0200 |
commit | 276725c4e2c8e06e3cec36472adb0be7d99b709d (patch) | |
tree | 8beb56b7d40f12f7c2b0d5226c697fd971dab9c3 /gnulib-tool.py | |
parent | c0c72120f0a9e1514d5a46d3588bf40bdbd20be4 (diff) | |
download | gnulib-276725c4e2c8e06e3cec36472adb0be7d99b709d.tar.gz |
gnulib-tool.py: Simplify.
* pygnulib/constants.py (compiler): Remove function.
* gnulib-tool.py: Use re.compile directly instead.
* pygnulib/*.py: Likewise.
Diffstat (limited to 'gnulib-tool.py')
-rwxr-xr-x | gnulib-tool.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gnulib-tool.py b/gnulib-tool.py index 21c6789ba9..1a6bd9e948 100755 --- a/gnulib-tool.py +++ b/gnulib-tool.py @@ -55,7 +55,6 @@ ENCS = constants.ENCS UTILS = constants.UTILS MODES = constants.MODES TESTS = constants.TESTS -compiler = constants.compiler joinpath = constants.joinpath copyfile = constants.copyfile isabs = os.path.isabs @@ -745,7 +744,7 @@ def main(): else: # if not isfile(filepath) filepath = joinpath(destdir, 'aclocal.m4') if isfile(filepath): - pattern = constants.compiler(r'm4_include\(\[(.*?)\]\)') + pattern = re.compile(r'm4_include\(\[(.*?)\]\)') with codecs.open(filepath, 'rb', 'UTF-8') as file: m4dirs = pattern.findall(file.read()) m4dirs = [ os.path.dirname(m4dir) |