mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-12 14:50:19 +02:00
* numbers.h: fix various preprocessor usages of new public
symbols to expect 0 or 1 values rather than 1 or undefined. i.e. change #ifdef to #if, etc.
This commit is contained in:
parent
b075613ec4
commit
f0ad7455ec
1 changed files with 23 additions and 21 deletions
|
@ -49,23 +49,23 @@
|
||||||
#include "libguile/__scm.h"
|
#include "libguile/__scm.h"
|
||||||
#include "libguile/print.h"
|
#include "libguile/print.h"
|
||||||
|
|
||||||
#if defined (SCM_HAVE_FLOATINGPOINT_H)
|
#if SCM_HAVE_FLOATINGPOINT_H
|
||||||
#include <floatingpoint.h>
|
# include <floatingpoint.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined (SCM_HAVE_IEEEFP_H)
|
#if SCM_HAVE_IEEEFP_H
|
||||||
#include <ieeefp.h>
|
# include <ieeefp.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined (SCM_HAVE_NAN_H)
|
#if SCM_HAVE_NAN_H
|
||||||
#if defined (SCO)
|
# if defined (SCO)
|
||||||
#define _IEEE 1
|
# define _IEEE 1
|
||||||
#endif
|
# endif
|
||||||
#include <nan.h>
|
# include <nan.h>
|
||||||
#if defined (SCO)
|
# if defined (SCO)
|
||||||
#undef _IEEE
|
# undef _IEEE
|
||||||
#endif
|
# endif
|
||||||
#endif
|
#endif /* SCM_HAVE_NAN_H */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -110,20 +110,22 @@
|
||||||
* SCM_FLTMAX is less than or scm_equal the largest single precision float
|
* SCM_FLTMAX is less than or scm_equal the largest single precision float
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef SCM_HAVE_STDC_HEADERS
|
#if SCM_HAVE_STDC_HEADERS
|
||||||
#ifndef GO32
|
# ifndef GO32
|
||||||
#include <float.h>
|
# include <float.h>
|
||||||
#endif /* ndef GO32 */
|
# endif /* ndef GO32 */
|
||||||
#endif /* def STDC_HEADERS */
|
#endif /* def STDC_HEADERS */
|
||||||
|
|
||||||
#ifdef DBL_MAX_10_EXP
|
#ifdef DBL_MAX_10_EXP
|
||||||
#define SCM_MAXEXP DBL_MAX_10_EXP
|
# define SCM_MAXEXP DBL_MAX_10_EXP
|
||||||
#else
|
#else
|
||||||
#define SCM_MAXEXP 308 /* IEEE doubles */
|
# define SCM_MAXEXP 308 /* IEEE doubles */
|
||||||
#endif /* def DBL_MAX_10_EXP */
|
#endif /* def DBL_MAX_10_EXP */
|
||||||
|
|
||||||
#ifdef FLT_MAX
|
#ifdef FLT_MAX
|
||||||
#define SCM_FLTMAX FLT_MAX
|
# define SCM_FLTMAX FLT_MAX
|
||||||
#else
|
#else
|
||||||
#define SCM_FLTMAX 1e+23
|
# define SCM_FLTMAX 1e+23
|
||||||
#endif /* def FLT_MAX */
|
#endif /* def FLT_MAX */
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue