summaryrefslogtreecommitdiffstats
path: root/lldb/test/tools/lldb-server/socket_packet_pump.py
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2015-10-23 17:04:29 +0000
committerZachary Turner <zturner@google.com>2015-10-23 17:04:29 +0000
commit35d017f0fc38b53e31f1a44d07c3c142f5d3620b (patch)
tree9bb8d7e92d30ed6ea5387993d53a07e8f16a155c /lldb/test/tools/lldb-server/socket_packet_pump.py
parentd43fe0bd39ab70b739123853ebd0c2991512b9d7 (diff)
downloadbcm5719-llvm-35d017f0fc38b53e31f1a44d07c3c142f5d3620b.tar.gz
bcm5719-llvm-35d017f0fc38b53e31f1a44d07c3c142f5d3620b.zip
Add from __future__ import print_function everywhere.
Apparently there were tons of instances I missed last time, I guess I accidentally ran 2to3 non-recursively. This should be every occurrence of a print statement fixed to use a print function as well as from __future__ import print_function being added to every file. After this patch print statements will stop working everywhere in the test suite, and the print function should be used instead. llvm-svn: 251121
Diffstat (limited to 'lldb/test/tools/lldb-server/socket_packet_pump.py')
-rw-r--r--lldb/test/tools/lldb-server/socket_packet_pump.py14
1 files changed, 8 insertions, 6 deletions
diff --git a/lldb/test/tools/lldb-server/socket_packet_pump.py b/lldb/test/tools/lldb-server/socket_packet_pump.py
index 780ff09b7c5..a6f42edb398 100644
--- a/lldb/test/tools/lldb-server/socket_packet_pump.py
+++ b/lldb/test/tools/lldb-server/socket_packet_pump.py
@@ -1,4 +1,6 @@
+from __future__ import print_function
+
import lldb_shared
import re
@@ -21,8 +23,8 @@ def _handle_output_packet_string(packet_contents):
def _dump_queue(the_queue):
while not the_queue.empty():
- print codecs.encode(the_queue.get(True), "string_escape")
- print "\n"
+ print(codecs.encode(the_queue.get(True), "string_escape"))
+ print("\n")
class SocketPacketPump(object):
"""A threaded packet reader that partitions packets into two streams.
@@ -67,15 +69,15 @@ class SocketPacketPump(object):
# Warn if there is any content left in any of the queues.
# That would represent unmatched packets.
if not self.output_queue().empty():
- print "warning: output queue entries still exist:"
+ print("warning: output queue entries still exist:")
_dump_queue(self.output_queue())
- print "from here:"
+ print("from here:")
traceback.print_stack()
if not self.packet_queue().empty():
- print "warning: packet queue entries still exist:"
+ print("warning: packet queue entries still exist:")
_dump_queue(self.packet_queue())
- print "from here:"
+ print("from here:")
traceback.print_stack()
def start_pump_thread(self):
OpenPOWER on IntegriCloud