Skip to content

Commit df66ff1

Browse files
authored
gh-128978: Fix a NameError in sysconfig.expand_makefile_vars (#128979)
This fixes a regression introduced by 4a53a39.
1 parent 59fcae7 commit df66ff1

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

Lib/sysconfig/__init__.py

+3
Original file line numberDiff line numberDiff line change
@@ -718,6 +718,9 @@ def expand_makefile_vars(s, vars):
718718
"""
719719
import re
720720

721+
_findvar1_rx = r"\$\(([A-Za-z][A-Za-z0-9_]*)\)"
722+
_findvar2_rx = r"\${([A-Za-z][A-Za-z0-9_]*)}"
723+
721724
# This algorithm does multiple expansion, so if vars['foo'] contains
722725
# "${bar}", it will expand ${foo} to ${bar}, and then expand
723726
# ${bar}... and so forth. This is fine as long as 'vars' comes from
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Fix a :exc:`NameError` in :func:`!sysconfig.expand_makefile_vars`. Patch by
2+
Bénédikt Tran.

0 commit comments

Comments
 (0)