@@ -247,7 +247,7 @@ def test_float_types():
247247def test_complex_types ():
248248 INF = 1E200 * 1E200
249249 for name in ["float" , "double" ]:
250- p = new_primitive_type ("_cffi_" + name + "_complex_t " )
250+ p = new_primitive_type (name + " _Complex " )
251251 assert bool (cast (p , 0 )) is False
252252 assert bool (cast (p , INF ))
253253 assert bool (cast (p , - INF ))
@@ -1246,7 +1246,7 @@ def test_call_function_9():
12461246
12471247def test_call_function_24 ():
12481248 BFloat = new_primitive_type ("float" )
1249- BFloatComplex = new_primitive_type ("_cffi_float_complex_t " )
1249+ BFloatComplex = new_primitive_type ("float _Complex " )
12501250 BFunc3 = new_function_type ((BFloat , BFloat ), BFloatComplex , False )
12511251 if 0 : # libffi returning nonsense silently, so logic disabled for now
12521252 f = cast (BFunc3 , _testfunc (24 ))
@@ -1260,7 +1260,7 @@ def test_call_function_24():
12601260
12611261def test_call_function_25 ():
12621262 BDouble = new_primitive_type ("double" )
1263- BDoubleComplex = new_primitive_type ("_cffi_double_complex_t " )
1263+ BDoubleComplex = new_primitive_type ("double _Complex " )
12641264 BFunc3 = new_function_type ((BDouble , BDouble ), BDoubleComplex , False )
12651265 if 0 : # libffi returning nonsense silently, so logic disabled for now
12661266 f = cast (BFunc3 , _testfunc (25 ))
@@ -4536,9 +4536,9 @@ def test_unaligned_types():
45364536 buf = buffer (pbuf )
45374537 #
45384538 for name in ['short' , 'int' , 'long' , 'long long' , 'float' , 'double' ,
4539- '_cffi_float_complex_t ' , '_cffi_double_complex_t ' ]:
4539+ 'float _Complex ' , 'double _Complex ' ]:
45404540 p = new_primitive_type (name )
4541- if name .endswith ('_complex_t ' ):
4541+ if name .endswith (' _Complex ' ):
45424542 num = cast (p , 1.23 - 4.56j )
45434543 else :
45444544 num = cast (p , 0x0123456789abcdef )
0 commit comments