[gobject-introspection] giscanner/msvccompiler.py: Make it compatible with Python 3.x



commit f12d853b98b638b1a65cd27eddf2fb06e6540249
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Wed Oct 28 16:10:24 2015 +0800

    giscanner/msvccompiler.py: Make it compatible with Python 3.x
    
    This is checked for Python 2.7.x compatibility as well.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=757126

 giscanner/msvccompiler.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/giscanner/msvccompiler.py b/giscanner/msvccompiler.py
index 6324809..d578577 100644
--- a/giscanner/msvccompiler.py
+++ b/giscanner/msvccompiler.py
@@ -80,8 +80,8 @@ class MSVCCompiler(distutils.msvccompiler.MSVCCompiler):
         if self.force or output_file is None or newer(source, output_file):
             try:
                 self.spawn(cpp_args)
-            except DistutilsExecError, msg:
-                print msg
+            except (DistutilsExecError, msg):
+                print(msg)
                 raise CompileError
 
         # The /P option for the MSVC preprocessor will output the results


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]