This is because these files are templates. If I remember correctly, NumPy uses several template engines (thanks @ user2357112 for help finding the right one):
and the second is responsible for converting them into "regular" C files - before they are compiled.
Basically, these functions will be cloned many times, and for each function a special placeholder tag is inserted between %.
For example, in this case begins with :
/**begin repeat
*
*
*
*
* ....
*/
, @ctype@ npy_cfloat @c@ f @c@ f:
static const npy_cfloat c_1f = {1.0F, 0.0};
static const npy_cfloat c_halff = {0.5F, 0.0};
static const npy_cfloat c_if = {0.0, 1.0F};
static const npy_cfloat c_ihalff = {0.0, 0.5F};
@ctype@ npy_cdouble,...
static const npy_cdouble c_1 = {1.0, 0.0};
static const npy_cdouble c_half = {0.5, 0.0};
static const npy_cdouble c_i = {0.0, 1.0};
static const npy_cdouble c_ihalf = {0.0, 0.5};
:
static const npy_clongdouble c_1l = {1.0L, 0.0};
static const npy_clongdouble c_halfl = {0.5L, 0.0};
static const npy_clongdouble c_il = {0.0, 1.0L};
static const npy_clongdouble c_ihalfl = {0.0, 0.5L};
C.