Home
last modified time | relevance | path

Searched refs:tuple (Results 1 – 25 of 244) sorted by relevance

12345678910

/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/test/
Dtest_tuple.py6 type2test = tuple
11 self.assertEqual(tuple(), ())
13 t0_3_bis = tuple(t0_3)
15 self.assertEqual(tuple([]), ())
16 self.assertEqual(tuple([0, 1, 2, 3]), (0, 1, 2, 3))
17 self.assertEqual(tuple(''), ())
18 self.assertEqual(tuple('spam'), ('s', 'p', 'a', 'm'))
50 self.assertEqual(list(tuple(f())), range(1000))
77 l0 = tuple()
130 check(tp(tuple([obj]) for obj in [1, x, y]))
[all …]
Dtest_pprint.py20 class tuple2(tuple):
23 class tuple3(tuple):
25 return tuple.__repr__(self)
159 o = tuple(range(100))
161 for type in [tuple, tuple2]:
Dtest_itertools.py89 pool = tuple(iterable)
94 yield tuple(pool[i] for i in indices)
104 yield tuple(pool[i] for i in indices)
108 pool = tuple(iterable)
112 yield tuple(pool[i] for i in indices)
116 pool = tuple(iterable)
120 yield tuple(pool[i] for i in indices)
156 pool = tuple(iterable)
161 yield tuple(pool[i] for i in indices)
169 yield tuple(pool[i] for i in indices)
[all …]
Dtest_structseq.py10 astuple = tuple(t)
39 t2 = t1 + tuple(t1)
58 self.assertEqual(hash(t1), hash(tuple(t1)))
Dtest_deque.py252 s = tuple('abcde')
263 self.assertEqual(tuple(d), s)
271 self.assertEqual(tuple(d), tuple(e))
273 self.assertEqual(tuple(d), s)
275 self.assertEqual(tuple(e), s)
283 self.assertEqual(tuple(d), tuple(e))
285 self.assertEqual(tuple(d), s)
287 self.assertEqual(tuple(e), s)
295 self.assertEqual(tuple(d), tuple(e))
Dtest_collections.py27 self.assertEqual(Point.__getitem__, tuple.__getitem__)
109 self.assertIsInstance(p, tuple)
111 … self.assertEqual(tuple(p), (11, 22)) # coercable to a real tuple
148 self.assertEqual(b, tuple(range(n)))
149 self.assertEqual(Big._make(range(n)), tuple(range(n)))
160 self.assertEqual(b2, tuple(b2_expected))
161 self.assertEqual(b._fields, tuple(names))
186 newt = t._replace(itemgetter=10, property=20, self=30, cls=40, tuple=50)
196 values = tuple(range(len(words)))
210 newvalues = tuple(v*10 for v in values)
[all …]
Dtest_iter.py291 self.assertEqual(tuple(SequenceClass(5)), (0, 1, 2, 3, 4))
292 self.assertEqual(tuple(SequenceClass(0)), ())
293 self.assertEqual(tuple([]), ())
294 self.assertEqual(tuple(()), ())
295 self.assertEqual(tuple("abc"), ("a", "b", "c"))
298 self.assertEqual(tuple(d), tuple(d.keys()))
300 self.assertRaises(TypeError, tuple, list)
301 self.assertRaises(TypeError, tuple, 42)
311 self.assertEqual(tuple(f), ("0\n", "1\n", "2\n", "3\n", "4\n"))
313 self.assertEqual(tuple(f),
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/compiler/
Dast.py11 if t is tuple or t is list:
74 return tuple(flatten(self.nodes))
79 return tuple(nodelist)
106 return tuple(flatten(self.nodes))
111 return tuple(nodelist)
137 return tuple(flatten(self.nodes))
142 return tuple(nodelist)
157 return tuple(children)
164 return tuple(nodelist)
179 return tuple(children)
[all …]
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Tools/unicode/
Dmkstringprep.py18 tuple = []
28 tuple.append((prev,prev+span+1))
37 tuple.append((prev,prev+span+1))
40 tuple = " + ".join(["range(%d,%d)" % t for t in tuple])
42 return "set(%s)" % tuple
43 if not tuple:
45 return "set(%s + %s)" % (repr(single),tuple)
Dgencodec.py68 return tuple(l)
157 if isinstance(mapkey, tuple):
159 if isinstance(mapvalue, tuple):
210 if isinstance(mapkey, tuple):
212 if isinstance(mapvalue, tuple):
233 if isinstance(mapvalue, tuple):
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Objects/
Dexceptions.c671 PyObject *tuple; in EnvironmentError_str() local
682 tuple = PyTuple_New(3); in EnvironmentError_str()
683 if (!tuple) { in EnvironmentError_str()
691 PyTuple_SET_ITEM(tuple, 0, self->myerrno); in EnvironmentError_str()
695 PyTuple_SET_ITEM(tuple, 0, Py_None); in EnvironmentError_str()
699 PyTuple_SET_ITEM(tuple, 1, self->strerror); in EnvironmentError_str()
703 PyTuple_SET_ITEM(tuple, 1, Py_None); in EnvironmentError_str()
706 PyTuple_SET_ITEM(tuple, 2, repr); in EnvironmentError_str()
708 rtnval = PyString_Format(fmt, tuple); in EnvironmentError_str()
711 Py_DECREF(tuple); in EnvironmentError_str()
[all …]
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Objects/
Dexceptions.c671 PyObject *tuple; in EnvironmentError_str() local
682 tuple = PyTuple_New(3); in EnvironmentError_str()
683 if (!tuple) { in EnvironmentError_str()
691 PyTuple_SET_ITEM(tuple, 0, self->myerrno); in EnvironmentError_str()
695 PyTuple_SET_ITEM(tuple, 0, Py_None); in EnvironmentError_str()
699 PyTuple_SET_ITEM(tuple, 1, self->strerror); in EnvironmentError_str()
703 PyTuple_SET_ITEM(tuple, 1, Py_None); in EnvironmentError_str()
706 PyTuple_SET_ITEM(tuple, 2, repr); in EnvironmentError_str()
708 rtnval = PyString_Format(fmt, tuple); in EnvironmentError_str()
711 Py_DECREF(tuple); in EnvironmentError_str()
[all …]
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/test/crashers/
Dgc_inspection.py27 [tup] = [x for x in gc.get_referrers(marker) if type(x) is tuple]
32 tuple(g())
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Modules/
D_testcapimodule.c792 PyObject *tuple, *num; in test_L_code() local
795 tuple = PyTuple_New(1); in test_L_code()
796 if (tuple == NULL) in test_L_code()
803 PyTuple_SET_ITEM(tuple, 0, num); in test_L_code()
806 if (PyArg_ParseTuple(tuple, "L:test_L_code", &value) < 0) in test_L_code()
817 PyTuple_SET_ITEM(tuple, 0, num); in test_L_code()
820 if (PyArg_ParseTuple(tuple, "L:test_L_code", &value) < 0) in test_L_code()
826 Py_DECREF(tuple); in test_L_code()
968 PyObject *tuple, *num; in test_k_code() local
971 tuple = PyTuple_New(1); in test_k_code()
[all …]
Ddatetimemodule.c1558 PyObject *tuple = NULL; in microseconds_to_delta_ex() local
1562 tuple = PyNumber_Divmod(pyus, us_per_second); in microseconds_to_delta_ex()
1563 if (tuple == NULL) in microseconds_to_delta_ex()
1566 num = PyTuple_GetItem(tuple, 1); /* us */ in microseconds_to_delta_ex()
1581 num = PyTuple_GetItem(tuple, 0); /* leftover seconds */ in microseconds_to_delta_ex()
1585 Py_DECREF(tuple); in microseconds_to_delta_ex()
1587 tuple = PyNumber_Divmod(num, seconds_per_day); in microseconds_to_delta_ex()
1588 if (tuple == NULL) in microseconds_to_delta_ex()
1592 num = PyTuple_GetItem(tuple, 1); /* seconds */ in microseconds_to_delta_ex()
1608 num = PyTuple_GetItem(tuple, 0); /* leftover days */ in microseconds_to_delta_ex()
[all …]
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/json/
Dencoder.py202 if not isinstance(chunks, (list, tuple)):
279 tuple=tuple, argument
320 if isinstance(value, (list, tuple)):
396 if isinstance(value, (list, tuple)):
424 elif isinstance(o, (list, tuple)):
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Lib/json/
Dencoder.py208 if not isinstance(chunks, (list, tuple)):
285 tuple=tuple, argument
326 if isinstance(value, (list, tuple)):
402 if isinstance(value, (list, tuple)):
430 elif isinstance(o, (list, tuple)):
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Tools/pybench/
DTuples.py12 t = tuple(range(100))
261 t = tuple(range(100))
291 t = tuple(l)
307 t = tuple(l)
323 t = tuple(l)
339 t = tuple(l)
355 t = tuple(l)
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/distutils/command/
Dbuild_clib.py134 if not isinstance(lib, tuple) and len(lib) != 2:
172 if sources is None or not isinstance(sources, (list, tuple)):
184 if sources is None or not isinstance(sources, (list, tuple)):
/device/google/cuttlefish_common/tools/play_audio/
Dplay_audio.cpp49 std::tuple<std::uint16_t, std::uint16_t> RecvHeader(cfp::ClientSocket* conn) { in RecvHeader()
59 std::tuple<std::uint32_t, std::vector<unsigned char>> RecvEncodedAudio( in RecvEncodedAudio()
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/
Dpprint.py177 (issubclass(typ, tuple) and r is tuple.__repr__) or
221 if issubclass(typ, tuple) and length == 1:
295 (issubclass(typ, tuple) and r is tuple.__repr__):
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/distutils/
Dccompiler.py232 if not (isinstance(defn, tuple) and
390 elif isinstance(incdirs, (list, tuple)):
450 elif isinstance(include_dirs, (list, tuple)):
464 if not isinstance(objects, (list, tuple)):
485 elif isinstance(libraries, (list, tuple)):
493 elif isinstance(library_dirs, (list, tuple)):
501 elif isinstance(runtime_library_dirs, (list, tuple)):
1082 if not (isinstance(macro, tuple) and
Dversion.py113 self.version = tuple(map(string.atoi, [major, minor, patch]))
115 self.version = tuple(map(string.atoi, [major, minor]) + [0])
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Modules/
Ddatetimemodule.c1558 PyObject *tuple = NULL; in microseconds_to_delta_ex() local
1562 tuple = PyNumber_Divmod(pyus, us_per_second); in microseconds_to_delta_ex()
1563 if (tuple == NULL) in microseconds_to_delta_ex()
1566 num = PyTuple_GetItem(tuple, 1); /* us */ in microseconds_to_delta_ex()
1581 num = PyTuple_GetItem(tuple, 0); /* leftover seconds */ in microseconds_to_delta_ex()
1585 Py_DECREF(tuple); in microseconds_to_delta_ex()
1587 tuple = PyNumber_Divmod(num, seconds_per_day); in microseconds_to_delta_ex()
1588 if (tuple == NULL) in microseconds_to_delta_ex()
1592 num = PyTuple_GetItem(tuple, 1); /* seconds */ in microseconds_to_delta_ex()
1608 num = PyTuple_GetItem(tuple, 0); /* leftover days */ in microseconds_to_delta_ex()
[all …]
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Lib/
Dcopy.py103 for t in (type(None), int, long, float, bool, str, tuple,
245 y = tuple(y)
251 d[tuple] = _deepcopy_tuple
309 assert isinstance(info, tuple)
338 if isinstance(state, tuple) and len(state) == 2:

12345678910