The recent update on this script to handle strings rather than bytes
missed a call to ".decode()", leading to a crash:

    AttributeError: 'str' object has no attribute 'decode'

Tested on x86_64-pc-linux-gnu, committed on trunk

gcc/ada/

        * doc/share/conf.py: Remove spurious call to ".decode()".
diff --git a/gcc/ada/doc/share/conf.py b/gcc/ada/doc/share/conf.py
--- a/gcc/ada/doc/share/conf.py
+++ b/gcc/ada/doc/share/conf.py
@@ -43,7 +43,7 @@ def get_gnat_version():
                   r'constant String := "([^\(\)]+)\(.*\)?";',
                   gnatvsn_content)
     if m:
-        return m.group(1).strip().decode()
+        return m.group(1).strip()
     else:
         if texi_fsf and os.path.exists(basever):
             return ''


Reply via email to