Kaydet (Commit) c654f0ac authored tarafından Martin Panter's avatar Martin Panter

Issues #29349: Add NEWS for 3.7; use “with” statement

üst 3a6dc19f
...@@ -22,15 +22,12 @@ def get_header_version_info(srcdir): ...@@ -22,15 +22,12 @@ def get_header_version_info(srcdir):
rx = re.compile(r'\s*#define\s+([a-zA-Z][a-zA-Z_0-9]*)\s+([a-zA-Z_0-9]+)') rx = re.compile(r'\s*#define\s+([a-zA-Z][a-zA-Z_0-9]*)\s+([a-zA-Z_0-9]+)')
d = {} d = {}
f = open(patchlevel_h) with open(patchlevel_h) as f:
try:
for line in f: for line in f:
m = rx.match(line) m = rx.match(line)
if m is not None: if m is not None:
name, value = m.group(1, 2) name, value = m.group(1, 2)
d[name] = value d[name] = value
finally:
f.close()
release = version = '%s.%s' % (d['PY_MAJOR_VERSION'], d['PY_MINOR_VERSION']) release = version = '%s.%s' % (d['PY_MAJOR_VERSION'], d['PY_MINOR_VERSION'])
micro = int(d['PY_MICRO_VERSION']) micro = int(d['PY_MICRO_VERSION'])
......
...@@ -663,6 +663,8 @@ C API ...@@ -663,6 +663,8 @@ C API
Documentation Documentation
------------- -------------
- Issue #29349: Fix Python 2 syntax in code for building the documentation.
- Issue #23722: The data model reference and the porting section in the - Issue #23722: The data model reference and the porting section in the
3.6 What's New guide now cover the additional ``__classcell__`` handling 3.6 What's New guide now cover the additional ``__classcell__`` handling
needed for custom metaclasses to fully support PEP 487 and zero-argument needed for custom metaclasses to fully support PEP 487 and zero-argument
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment