summaryrefslogtreecommitdiff
path: root/proto/xcb-proto/xcbgen/state.py
diff options
context:
space:
mode:
Diffstat (limited to 'proto/xcb-proto/xcbgen/state.py')
-rw-r--r--proto/xcb-proto/xcbgen/state.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/proto/xcb-proto/xcbgen/state.py b/proto/xcb-proto/xcbgen/state.py
index 0dbecdc7b..ffbfc14ee 100644
--- a/proto/xcb-proto/xcbgen/state.py
+++ b/proto/xcb-proto/xcbgen/state.py
@@ -2,7 +2,12 @@
This module contains the namespace class and the singleton module class.
'''
from os.path import dirname, basename
-from xml.etree.cElementTree import parse
+from sys import version_info
+
+if version_info[:2] >= (3, 3):
+ from xml.etree.ElementTree import parse
+else:
+ from xml.etree.cElementTree import parse
from xcbgen import matcher
from xcbgen.error import *