]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libstdc++: Fix std::error_code pretty printer for versioned namespace
authorJonathan Wakely <jwakely@redhat.com>
Wed, 5 Jan 2022 14:06:43 +0000 (14:06 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Wed, 5 Jan 2022 17:53:37 +0000 (17:53 +0000)
libstdc++-v3/ChangeLog:

* python/libstdcxx/v6/printers.py (StdErrorCodePrinter): Strip
versioned namespace from the type name that is printed.

(cherry picked from commit 1918067e2d0d79ccaf1e4ed98096060fc235e772)

libstdc++-v3/python/libstdcxx/v6/printers.py

index 83e0d2e7e34d5cc01dfce876a16f965efbad2d25..74c629a710c8ac69cd42df697dbeb0beb06acd51 100644 (file)
@@ -1503,7 +1503,7 @@ class StdErrorCodePrinter:
 
     def __init__ (self, typename, val):
         self.val = val
-        self.typename = typename
+        self.typename = strip_versioned_namespace(typename)
         # Do this only once ...
         if StdErrorCodePrinter._errno_categories is None:
             StdErrorCodePrinter._errno_categories = ['generic']