serge-sans-paille created this revision.
serge-sans-paille added a reviewer: michaelplatings.
Herald added subscribers: lldb-commits, jdoerfert.
Herald added a project: LLDB.

Repository:
  rLLDB LLDB

https://reviews.llvm.org/D59586

Files:
  lldb/examples/python/lldbtk.py


Index: lldb/examples/python/lldbtk.py
===================================================================
--- lldb/examples/python/lldbtk.py
+++ lldb/examples/python/lldbtk.py
@@ -1,10 +1,15 @@
 #!/usr/bin/python
+from __future__ import print_function
 
 import lldb
 import shlex
 import sys
-from Tkinter import *
-import ttk
+try:
+    from tkinter import *
+    import tkinter.ttk as ttk
+except ImportError:
+    from Tkinter import *
+    import ttk
 
 
 class ValueTreeItemDelegate(object):


Index: lldb/examples/python/lldbtk.py
===================================================================
--- lldb/examples/python/lldbtk.py
+++ lldb/examples/python/lldbtk.py
@@ -1,10 +1,15 @@
 #!/usr/bin/python
+from __future__ import print_function
 
 import lldb
 import shlex
 import sys
-from Tkinter import *
-import ttk
+try:
+    from tkinter import *
+    import tkinter.ttk as ttk
+except ImportError:
+    from Tkinter import *
+    import ttk
 
 
 class ValueTreeItemDelegate(object):
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to