2003-02-01 09:49:15 +08:00
|
|
|
/*
|
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
| Zend Engine |
|
|
|
|
+----------------------------------------------------------------------+
|
2008-12-31 19:15:49 +08:00
|
|
|
| Copyright (c) 1998-2009 Zend Technologies Ltd. (http://www.zend.com) |
|
2003-02-01 09:49:15 +08:00
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
| This source file is subject to version 2.00 of the Zend license, |
|
|
|
|
| that is bundled with this package in the file LICENSE, and is |
|
2003-06-11 04:04:29 +08:00
|
|
|
| available through the world-wide-web at the following url: |
|
2003-02-01 09:49:15 +08:00
|
|
|
| http://www.zend.com/license/2_00.txt. |
|
|
|
|
| If you did not receive a copy of the Zend license and are unable to |
|
|
|
|
| obtain it through the world-wide-web, please send a note to |
|
|
|
|
| license@zend.com so we can mail you a copy immediately. |
|
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
| Authors: Andi Gutmans <andi@zend.com> |
|
|
|
|
| Zeev Suraski <zeev@zend.com> |
|
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* $Id$ */
|
|
|
|
|
2008-01-30 17:41:12 +08:00
|
|
|
#if defined(__GNUC__) && __GNUC__ >= 4
|
|
|
|
# define ZEND_API __attribute__ ((visibility("default")))
|
|
|
|
# define ZEND_DLEXPORT __attribute__ ((visibility("default")))
|
|
|
|
#else
|
|
|
|
# define ZEND_API
|
|
|
|
# define ZEND_DLEXPORT
|
|
|
|
#endif
|
|
|
|
|
2002-04-22 17:33:25 +08:00
|
|
|
#define ZEND_DLIMPORT
|
1999-09-07 00:14:08 +08:00
|
|
|
|
2005-02-22 21:49:52 +08:00
|
|
|
@TOP@
|
|
|
|
|
1999-04-08 02:10:10 +08:00
|
|
|
#undef uint
|
|
|
|
#undef ulong
|
|
|
|
|
|
|
|
/* Define if you want to enable memory limit support */
|
|
|
|
#define MEMORY_LIMIT 0
|
|
|
|
|
2005-02-22 21:49:52 +08:00
|
|
|
@BOTTOM@
|
1999-09-07 00:14:08 +08:00
|
|
|
|
2004-01-10 07:37:29 +08:00
|
|
|
#ifndef ZEND_ACCONFIG_H_NO_C_PROTOS
|
|
|
|
|
1999-09-07 17:02:41 +08:00
|
|
|
#ifdef HAVE_STDLIB_H
|
|
|
|
# include <stdlib.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef HAVE_SYS_TYPES_H
|
|
|
|
# include <sys/types.h>
|
|
|
|
#endif
|
|
|
|
|
2004-10-08 15:43:41 +08:00
|
|
|
#ifdef HAVE_SYS_SELECT_H
|
|
|
|
#include <sys/select.h>
|
|
|
|
#endif
|
|
|
|
|
2001-03-12 03:35:26 +08:00
|
|
|
#ifdef HAVE_IEEEFP_H
|
|
|
|
# include <ieeefp.h>
|
|
|
|
#endif
|
|
|
|
|
1999-09-07 17:02:41 +08:00
|
|
|
#ifdef HAVE_STRING_H
|
|
|
|
# include <string.h>
|
|
|
|
#else
|
|
|
|
# include <strings.h>
|
|
|
|
#endif
|
|
|
|
|
1999-09-07 00:14:08 +08:00
|
|
|
#if ZEND_BROKEN_SPRINTF
|
|
|
|
int zend_sprintf(char *buffer, const char *format, ...);
|
|
|
|
#else
|
|
|
|
# define zend_sprintf sprintf
|
|
|
|
#endif
|
|
|
|
|
2000-08-20 14:09:07 +08:00
|
|
|
#include <math.h>
|
|
|
|
|
2004-09-22 20:45:28 +08:00
|
|
|
/* To enable the is_nan, is_infinite and is_finite PHP functions */
|
|
|
|
#ifdef NETWARE
|
|
|
|
#define HAVE_ISNAN 1
|
|
|
|
#define HAVE_ISINF 1
|
|
|
|
#define HAVE_ISFINITE 1
|
|
|
|
#endif
|
|
|
|
|
2003-02-25 15:46:15 +08:00
|
|
|
#ifndef zend_isnan
|
2000-08-20 14:07:42 +08:00
|
|
|
#ifdef HAVE_ISNAN
|
|
|
|
#define zend_isnan(a) isnan(a)
|
2001-03-12 03:35:26 +08:00
|
|
|
#elif defined(HAVE_FPCLASS)
|
|
|
|
#define zend_isnan(a) ((fpclass(a) == FP_SNAN) || (fpclass(a) == FP_QNAN))
|
2000-08-20 14:07:42 +08:00
|
|
|
#else
|
|
|
|
#define zend_isnan(a) 0
|
|
|
|
#endif
|
2003-02-25 15:46:15 +08:00
|
|
|
#endif
|
2000-08-20 14:07:42 +08:00
|
|
|
|
|
|
|
#ifdef HAVE_ISINF
|
|
|
|
#define zend_isinf(a) isinf(a)
|
|
|
|
#elif defined(INFINITY)
|
|
|
|
/* Might not work, but is required by ISO C99 */
|
|
|
|
#define zend_isinf(a) (((a)==INFINITY)?1:0)
|
2001-03-12 03:35:26 +08:00
|
|
|
#elif defined(HAVE_FPCLASS)
|
|
|
|
#define zend_isinf(a) ((fpclass(a) == FP_PINF) || (fpclass(a) == FP_NINF))
|
2000-08-20 14:07:42 +08:00
|
|
|
#else
|
|
|
|
#define zend_isinf(a) 0
|
|
|
|
#endif
|
|
|
|
|
2000-06-19 00:33:15 +08:00
|
|
|
#ifdef HAVE_FINITE
|
|
|
|
#define zend_finite(a) finite(a)
|
2000-08-20 15:12:48 +08:00
|
|
|
#elif defined(HAVE_ISFINITE) || defined(isfinite)
|
2000-06-19 00:33:15 +08:00
|
|
|
#define zend_finite(a) isfinite(a)
|
2000-08-20 15:12:48 +08:00
|
|
|
#elif defined(fpclassify)
|
|
|
|
#define zend_finite(a) ((fpclassify((a))!=FP_INFINITE&&fpclassify((a))!=FP_NAN)?1:0)
|
2000-06-19 00:33:15 +08:00
|
|
|
#else
|
2000-08-20 14:07:42 +08:00
|
|
|
#define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1)
|
2000-06-19 00:33:15 +08:00
|
|
|
#endif
|
|
|
|
|
2004-01-10 07:37:29 +08:00
|
|
|
#endif /* ifndef ZEND_ACCONFIG_H_NO_C_PROTOS */
|
|
|
|
|
2005-07-29 17:20:32 +08:00
|
|
|
#ifdef NETWARE
|
|
|
|
#ifdef USE_WINSOCK
|
|
|
|
#/*This detection against winsock is of no use*/ undef HAVE_SOCKLEN_T
|
|
|
|
#/*This detection against winsock is of no use*/ undef HAVE_SYS_SOCKET_H
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
1999-09-07 00:14:08 +08:00
|
|
|
/*
|
|
|
|
* Local variables:
|
|
|
|
* tab-width: 4
|
|
|
|
* c-basic-offset: 4
|
2003-02-01 09:49:15 +08:00
|
|
|
* indent-tabs-mode: t
|
1999-09-07 00:14:08 +08:00
|
|
|
* End:
|
|
|
|
*/
|