pike.git / src / modules / Math / math_module.c

version» Context lines:

pike.git/src/modules/Math/math_module.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information.   */      #include "global.h"   #include "config.h"   #include "program.h"   #include "module.h" + #include "pike_float.h"      #include "math_module.h"   #include "transforms.h"         /*** module init & exit & stuff *****************************************/      /* add other parsers here */      struct program *math_matrix_program;
pike.git/src/modules/Math/math_module.c:72:    exit_math_matrix();    exit_math_imatrix();    exit_math_fmatrix();    exit_math_smatrix();    exit_math_transforms();   }      PIKE_MODULE_INIT   {    int i; -  DECLARE_INF -  DECLARE_NAN -  +     for (i=0; i<(int)(sizeof(sub)/sizeof(sub[0])); i++)    {    struct program *p;       start_new_program();    sub[i].func();    p=end_program();    add_program_constant(sub[i].name,p,0);    if (sub[i].pd) sub[i].pd[0]=p;    else free_program(p);    }       add_float_constant("pi",3.14159265358979323846 ,0);    add_float_constant("e", 2.7182818284590452354 ,0); -  add_float_constant("inf", MAKE_INF(1), 0); +  add_float_constant("inf", MAKE_INF(), 0);    add_float_constant("nan", MAKE_NAN(), 0);   }