Home | History | Annotate | Download | only in test

Lines Matching refs:POINTER

91         from ctypes import c_short, c_uint, c_int, c_long, POINTER, pointer
92 LPINT = POINTER(c_int)
94 ## p = pointer(c_int(42))
96 x = LPINT.from_param(pointer(c_int(42)))
103 self.assertRaises(TypeError, LPINT.from_param, pointer(c_long(42)))
104 self.assertRaises(TypeError, LPINT.from_param, pointer(c_uint(42)))
105 self.assertRaises(TypeError, LPINT.from_param, pointer(c_short(42)))
108 # The from_param class method of POINTER(typ) classes accepts what is
110 from ctypes import c_short, c_uint, c_int, c_long, pointer, POINTER, byref
111 LPINT = POINTER(c_int)
122 from ctypes import c_short, c_uint, c_int, c_long, pointer, POINTER, byref
124 LPLPINT = POINTER(POINTER(c_int))
125 LPLPINT.from_param(byref(pointer(c_int(42))))
127 self.assertRaises(TypeError, LPLPINT.from_param, byref(pointer(c_short(22))))
129 self.assertRaises(TypeError, LPLPINT.from_param, byref(pointer(c_long(22))))
130 self.assertRaises(TypeError, LPLPINT.from_param, byref(pointer(c_uint(22))))
133 from ctypes import c_short, c_uint, c_int, c_long, POINTER
141 LPINT = POINTER(c_int)