There is an updated pull request by meator against master on the void-packages repository https://github.com/meator/void-packages pretty https://github.com/void-linux/void-packages/pull/47665 libstdc++: Fix pretty printer warnings Every time a C++ program is debugged under gdb, the following message is printed: ``` /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/printers.py:1201: SyntaxWarning: invalid escape sequence '\d' self.typename = re.sub('^std::experimental::fundamentals_v\d::', 'std::experimental::', self.typename, 1) /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/printers.py:1219: SyntaxWarning: invalid escape sequence '\w' mgrname = re.sub("std::string(?!\w)", str(gdb.lookup_type('std::string').strip_typedefs()), m.group(1)) /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/printers.py:1249: SyntaxWarning: invalid escape sequence '\d' self.typename = re.sub('^std::(experimental::|)(fundamentals_v\d::|)(.*)', r'std::\1\3<%s>' % valtype, typename, 1) /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:151: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?array<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:268: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?deque<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:312: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?forward_list<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:393: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?(__cxx11::)?list<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:508: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?vector<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:557: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?%s<.*>$' % self._name, class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:590: SyntaxWarning: invalid escape sequence '\d' if re.match('^std::(__\d+::)?__uniq_ptr_(data|impl)<.*>$', impl_type): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:592: SyntaxWarning: invalid escape sequence '\d' elif re.match('^std::(__\d+::)?tuple<.*>$', impl_type): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:654: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?unique_ptr<.*>$', class_type.tag): /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:723: SyntaxWarning: invalid escape sequence '\[' m = re.match('.*\[(\d+)]$', str(self._elem_type)) /usr/lib/../share/gcc-12.2.0/python/libstdcxx/v6/xmethods.py:772: SyntaxWarning: invalid escape sequence '\d' if not re.match('^std::(__\d+::)?shared_ptr<.*>$', class_type.tag): ``` This is fixed in the up to date version of the pretty printers in libstdc++ (in gcc). This is a temporary solution until gcc is updated. I have made a patch that uses raw string literals on these lines which makes the warnings go away. #### Testing the changes - I tested the changes in this PR: **briefly** (I have tested the modified `xmethods.py` and `printers.py` but I haven't compiled gcc for it.) [ci skip] #### Local build testing - none, gcc itself wasn't changed, only "data files" were modified, the build should act the same as the revision 3 build A patch file from https://github.com/void-linux/void-packages/pull/47665.patch is attached