Home
last modified time | relevance | path

Searched refs:c_short (Results 1 – 23 of 23) sorted by relevance

/third_party/python/Lib/ctypes/test/
Dtest_bitfields.py19 ("M", c_short, 1),
20 ("N", c_short, 2),
21 ("O", c_short, 3),
22 ("P", c_short, 4),
23 ("Q", c_short, 5),
24 ("R", c_short, 6),
25 ("S", c_short, 7)]
53 signed_int_types = (c_byte, c_short, c_int, c_long, c_longlong)
167 _fields_ = [("a", c_short, 1),
168 ("b", c_short, 14),
[all …]
Dtest_pep3118.py118 s_short = {2: 'h', 4: 'l', 8: 'q'}[sizeof(c_short)]
151 (c_short, "<" + s_short, (), c_short),
180 (POINTER(c_short) * 2, "&<" + s_short, (2,), POINTER(c_short)),
181 (POINTER(c_short) * 2 * 3, "&<" + s_short, (3,2,), POINTER(c_short)),
182 (POINTER(c_short * 2), "&(2)<" + s_short, (), POINTER(c_short)),
Dtest_byteswap.py47 self.assertIs(c_short.__ctype_le__, c_short)
48 self.assertIs(c_short.__ctype_be__.__ctype_le__, c_short)
50 self.assertIs(c_short.__ctype_be__, c_short)
51 self.assertIs(c_short.__ctype_le__.__ctype_be__, c_short)
52 s = c_short.__ctype_be__(0x1234)
57 s = c_short.__ctype_le__(0x1234)
183 ("c", c_short),
251 ("h", c_short),
271 ("h", c_short),
298 ("h", c_short),
Dtest_parameters.py83 from ctypes import c_short, c_uint, c_int, c_long, POINTER, pointer
97 self.assertRaises(TypeError, LPINT.from_param, pointer(c_short(42)))
102 from ctypes import c_short, c_uint, c_int, c_long, POINTER, byref
107 self.assertRaises(TypeError, LPINT.from_param, byref(c_short(22)))
114 from ctypes import c_short, c_uint, c_int, c_long, pointer, POINTER, byref
119 self.assertRaises(TypeError, LPLPINT.from_param, byref(pointer(c_short(22))))
125 from ctypes import c_short, c_uint, c_int, c_long, POINTER
135 self.assertRaises(TypeError, LPINT.from_param, c_short*3)
211 c_short,
231 self.assertEqual(repr(c_short.from_param(511)), "<cparam 'h' (511)>")
Dtest_functions.py68 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double]
83 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double]
95 f.restype = c_short
109 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double]
121 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double]
133 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_longdouble]
147 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double]
153 f.argtypes = [c_byte, c_short, c_int, c_long, c_float, c_double, c_longlong]
195 self.assertRaises(ArgumentError, f, byref(c_short(22)))
326 _fields_ = [("x", c_short),
[all …]
Dtest_arrays.py10 formats = c_byte, c_ubyte, c_short, c_ushort, c_int, c_uint, \
156 _type_ = c_short
166 self.assertEqual(X._type_, c_short)
168 self.assertEqual(X()._type_, c_short)
Dtest_cfuncs.py43 self._dll.tf_h.restype = c_short
44 self._dll.tf_h.argtypes = (c_short,)
49 self._dll.tf_bh.restype = c_short
50 self._dll.tf_bh.argtypes = (c_byte, c_short)
Dtest_cast.py15 if 2*sizeof(c_short) == sizeof(c_int):
16 ptr = cast(array, POINTER(c_short))
Dtest_repr.py5 for base in [c_byte, c_short, c_int, c_long, c_longlong,
Dtest_unaligned_structures.py13 for typ in [c_short, c_int, c_long, c_longlong,
Dtest_as_parameter.py164 _fields_ = [("x", c_short),
165 ("y", c_short)]
Dtest_slicing.py148 if sizeof(c_wchar) == sizeof(c_short):
149 dll.my_wcsdup.restype = POINTER(c_short)
Dtest_callbacks.py47 self.check_type(c_short, 42)
48 self.check_type(c_short, -42)
Dtest_pointers.py6 ctype_types = [c_byte, c_ubyte, c_short, c_ushort, c_int, c_uint,
Dtest_prototypes.py87 func.argtypes = POINTER(c_short),
Dtest_numbers.py25 signed_types = [c_byte, c_short, c_int, c_long, c_longlong]
Dtest_structures.py58 "h": c_short,
/third_party/python/Lib/ctypes/
D__init__.py163 class c_short(_SimpleCData): class
165 _check_size(c_short)
553 for kind in [c_short, c_int, c_long, c_longlong]:
Dwintypes.py29 SHORT = ctypes.c_short
/third_party/python/Lib/multiprocessing/
Dsharedctypes.py28 'h': ctypes.c_short, 'H': ctypes.c_ushort,
/third_party/python/Lib/lib2to3/tests/data/
Dinfinite_recursion.py24 __int16_t = c_short
2039 ('_flags', c_short),
2040 ('_file', c_short),
2480 int16_t = c_short
/third_party/python/Doc/library/
Dctypes.rst228 | :class:`c_short` | :c:type:`short` | int |
1206 >>> short_array = (c_short * 4)()
2239 :class:`c_short`.
2266 .. class:: c_short
Dmultiprocessing.rst1579 (c_short * 7)() RawArray(c_short, 7) RawArray('h', 7)