[gobject-introspection] [scanner] Make it compatible with Python 2.5 again



commit 2eb614e805311841e17fd4dbe76aa70443f3a911
Author: Johan Dahlin <johan gnome org>
Date:   Tue Sep 7 10:39:55 2010 -0300

    [scanner] Make it compatible with Python 2.5 again
    
    with statement is available in python 2.5, but only
    if you import it from __future__

 giscanner/codegen.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/giscanner/codegen.py b/giscanner/codegen.py
index 0c0c559..b73a7da 100644
--- a/giscanner/codegen.py
+++ b/giscanner/codegen.py
@@ -18,7 +18,10 @@
 # Boston, MA 02111-1307, USA.
 #
 
+from __future__ import with_statement
+
 from contextlib import contextmanager
+
 from . import ast
 
 class CCodeGenerator(object):



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