#NEWLINE# def test_some_float_type( ) : #NEWLINE# #INDENT# ffi = FFI ( ) #NEWLINE# ffi . cdef ( '\n        typedef double... foo_t;\n        typedef float... bar_t;\n        foo_t sum(foo_t[]);\n        bar_t neg(bar_t);\n        ' ) #NEWLINE# lib = verify ( lib , 'test_some_float_type' , '\n        typedef float foo_t;\n        static foo_t sum(foo_t x[]) { return x[0] + x[1]; }\n        typedef double bar_t;\n        static double neg(double x) { return -x; }\n    ' ) #NEWLINE# assert ( lib . sum ( [ 40.0 , 2.25 ] ) == 42.25 ) #NEWLINE# assert ( lib . sum ( [ 12.3 , 45.6 ] ) != ( 12.3 + 45.6 ) ) #NEWLINE# assert ( lib . neg ( 12.3 ) == ( - 12.3 ) ) #NEWLINE# assert ( ffi . sizeof ( 'foo_t' ) == ffi . sizeof ( 'float' ) ) #NEWLINE# assert ( ffi . sizeof ( 'bar_t' ) == ffi . sizeof ( 'double' ) )