aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2023-09-28 20:52:01 +0100
committerJonathan Wakely <jwakely@redhat.com>2023-09-28 21:20:27 +0100
commit17d3477fa89466604bee5af2a2caf8de5441aeb5 (patch)
treea5ede789369827d9d67475cf150c74eb46e66a33 /gcc
parent6b5c3f9b8139d9eee358b354b35da0b757a0270d (diff)
downloadgcc-17d3477fa89466604bee5af2a2caf8de5441aeb5.zip
gcc-17d3477fa89466604bee5af2a2caf8de5441aeb5.tar.gz
gcc-17d3477fa89466604bee5af2a2caf8de5441aeb5.tar.bz2
libstdc++: Refactor Python Xmethods to use is_specialization_of
This copies the is_specialization_of function from printers.py (with slight modification for versioned namespace handling) and reuses it in xmethods.py to replace repetitive re.match calls in every class. This fixes the problem that the regular expressions used \d without escaping the backslash properly. libstdc++-v3/ChangeLog: * python/libstdcxx/v6/xmethods.py (is_specialization_of): Define new function. (ArrayMethodsMatcher, DequeMethodsMatcher) (ForwardListMethodsMatcher, ListMethodsMatcher) (VectorMethodsMatcher, AssociativeContainerMethodsMatcher) (UniquePtrGetWorker, UniquePtrMethodsMatcher) (SharedPtrSubscriptWorker, SharedPtrMethodsMatcher): Use is_specialization_of instead of re.match.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions