bpo-44786: Fix a warning in RE in c-analyzer (GH-28351)

This commit is contained in:
Serhiy Storchaka 2021-09-15 17:08:48 +03:00 committed by GitHub
parent 11cdf2a670
commit 1a9ef57985
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

@ -0,0 +1 @@
Fix a warning in regular expression in the c-analyzer script.

View file

@ -236,12 +236,12 @@ def build_table(specs, *, sep=' ', defaultwidth=None):
_COLSPEC_RE = re.compile(textwrap.dedent(r''' _COLSPEC_RE = re.compile(textwrap.dedent(r'''
^ ^
(?: (?:
[[] \[
( (
(?: [^\s\]] [^\]]* )? (?: [^\s\]] [^\]]* )?
[^\s\]] [^\s\]]
) # <label> ) # <label>
[]] ]
)? )?
( \w+ ) # <field> ( \w+ ) # <field>
(?: (?: