Index: test/functionalities/abbreviation/TestCommonShortSpellings.py =================================================================== --- test/functionalities/abbreviation/TestCommonShortSpellings.py +++ test/functionalities/abbreviation/TestCommonShortSpellings.py @@ -32,7 +32,7 @@ ('ta st li', 'target stop-hook list'), ] - for (short, long) in abbrevs: - command_interpreter.ResolveCommand(short, result) + for (short_val, long_val) in abbrevs: + command_interpreter.ResolveCommand(short_val, result) self.assertTrue(result.Succeeded()) - self.assertEqual(long, result.GetOutput()) + self.assertEqual(long_val, result.GetOutput()) Index: test/lang/c/array_types/TestArrayTypes.py =================================================================== --- test/lang/c/array_types/TestArrayTypes.py +++ test/lang/c/array_types/TestArrayTypes.py @@ -182,7 +182,7 @@ "Variable 'long_6' should have 6 children") child5 = variable.GetChildAtIndex(5) self.DebugSBValue(child5) - self.assertTrue(long(child5.GetValue(), 0) == 6, + self.assertTrue(int(child5.GetValue(), 0) == 6, "long_6[5] == 6") # Last, check that "long_6" has a value type of eValueTypeVariableLocal Index: test/lldbcurses.py =================================================================== --- test/lldbcurses.py +++ test/lldbcurses.py @@ -1,5 +1,8 @@ +import lldb_shared + import curses, curses.panel import sys +import six import time class Point(object): @@ -138,7 +141,7 @@ for key in arg: self.add_key_action(key, callback, description) else: - if isinstance(arg, ( int, long )): + if isinstance(arg, six.integer_types): key_action_dict = { 'key' : arg, 'callback' : callback, 'description' : decription } Index: test/python_api/sbdata/TestSBData.py =================================================================== --- test/python_api/sbdata/TestSBData.py +++ test/python_api/sbdata/TestSBData.py @@ -220,8 +220,8 @@ self.assertTrue(data2.uint8[4] == 111, 'o == 111') self.assert_data(data2.GetUnsignedInt8, 5, 33) # ! - uint_lists = [ [1,2,3,4,5], [long(i) for i in [1, 2, 3, 4, 5]] ] - int_lists = [ [2, -2], [long(i) for i in [2, -2]] ] + uint_lists = [ [1,2,3,4,5], [int(i) for i in [1, 2, 3, 4, 5]] ] + int_lists = [ [2, -2], [int(i) for i in [2, -2]] ] for l in uint_lists: data2 = lldb.SBData.CreateDataFromUInt64Array(process.GetByteOrder(), process.GetAddressByteSize(), l) Index: test/tools/lldb-server/lldbgdbserverutils.py =================================================================== --- test/tools/lldb-server/lldbgdbserverutils.py +++ test/tools/lldb-server/lldbgdbserverutils.py @@ -9,6 +9,7 @@ import os.path import platform import re +import six import socket_packet_pump import subprocess import time @@ -808,8 +809,8 @@ If we don't know how to check running process ids on the given OS: return the value provided by the unknown_value arg. """ - if type(pid) not in [int, long]: - raise Exception("pid must be of type int (actual type: %s)" % str(type(pid))) + if not isinstance(pid, six.integer_types): + raise Exception("pid must be an integral type (actual type: %s)" % str(type(pid))) process_ids = []