diff options
-rw-r--r-- | Misc/NEWS.d/next/Tools-Demos/2021-09-14-11-44-26.bpo-44786.DU0LC0.rst | 1 | ||||
-rw-r--r-- | Tools/c-analyzer/c_common/tables.py | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/Misc/NEWS.d/next/Tools-Demos/2021-09-14-11-44-26.bpo-44786.DU0LC0.rst b/Misc/NEWS.d/next/Tools-Demos/2021-09-14-11-44-26.bpo-44786.DU0LC0.rst new file mode 100644 index 0000000..96ebf2c --- /dev/null +++ b/Misc/NEWS.d/next/Tools-Demos/2021-09-14-11-44-26.bpo-44786.DU0LC0.rst @@ -0,0 +1 @@ +Fix a warning in regular expression in the c-analyzer script. diff --git a/Tools/c-analyzer/c_common/tables.py b/Tools/c-analyzer/c_common/tables.py index 85b5019..130be6b 100644 --- a/Tools/c-analyzer/c_common/tables.py +++ b/Tools/c-analyzer/c_common/tables.py @@ -236,12 +236,12 @@ def build_table(specs, *, sep=' ', defaultwidth=None): _COLSPEC_RE = re.compile(textwrap.dedent(r''' ^ (?: - [[] + \[ ( (?: [^\s\]] [^\]]* )? [^\s\]] ) # <label> - []] + ] )? ( \w+ ) # <field> (?: |