mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-22 04:30:19 +02:00
* __scm.h: don't define long_long or ulong_long if HAVE_LONG_LONGS
is not defined. * stime.c (scm_localtime, scm_mktime): if neither HAVE_TM_ZONE nor HAVE_TZNAME are defined, use an empty string instead of giving two spurious compile-time errors.
This commit is contained in:
parent
4ba473028c
commit
43ff3170df
3 changed files with 26 additions and 20 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
2000-02-08 Gary Houston <ghouston@arglist.com>
|
||||||
|
|
||||||
|
* __scm.h: don't define long_long or ulong_long if HAVE_LONG_LONGS
|
||||||
|
is not defined.
|
||||||
|
|
||||||
|
* stime.c (scm_localtime, scm_mktime): if neither HAVE_TM_ZONE nor
|
||||||
|
HAVE_TZNAME are defined, use an empty string instead of giving two
|
||||||
|
spurious compile-time errors.
|
||||||
|
|
||||||
Tue Feb 8 13:57:46 2000 Greg J. Badros <gjb@cs.washington.edu>
|
Tue Feb 8 13:57:46 2000 Greg J. Badros <gjb@cs.washington.edu>
|
||||||
|
|
||||||
* ports.c: Doc patches from Richard Kim. Pasted from MIT Scheme.
|
* ports.c: Doc patches from Richard Kim. Pasted from MIT Scheme.
|
||||||
|
|
|
@ -107,16 +107,19 @@
|
||||||
#define STACK_CHECKING
|
#define STACK_CHECKING
|
||||||
#undef NO_CEVAL_STACK_CHECKING
|
#undef NO_CEVAL_STACK_CHECKING
|
||||||
|
|
||||||
|
|
||||||
|
/* What did the configure script discover about the outside world? */
|
||||||
|
#include "libguile/scmconfig.h"
|
||||||
|
|
||||||
|
#ifdef HAVE_LONG_LONGS
|
||||||
|
|
||||||
/* Some auto-generated .h files contain unused prototypes
|
/* Some auto-generated .h files contain unused prototypes
|
||||||
* that need these typedefs.
|
* that need these typedefs.
|
||||||
*/
|
*/
|
||||||
typedef long long long_long;
|
typedef long long long_long;
|
||||||
typedef unsigned long long ulong_long;
|
typedef unsigned long long ulong_long;
|
||||||
|
|
||||||
|
#endif /* HAVE_LONG_LONGS */
|
||||||
|
|
||||||
/* What did the configure script discover about the outside world? */
|
|
||||||
#include "libguile/scmconfig.h"
|
|
||||||
|
|
||||||
|
|
||||||
/* Write prototype declarations like this:
|
/* Write prototype declarations like this:
|
||||||
|
|
|
@ -330,7 +330,6 @@ restorezone (SCM zone, char **oldenv, const char *subr)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
SCM_DEFINE (scm_localtime, "localtime", 1, 1, 0,
|
SCM_DEFINE (scm_localtime, "localtime", 1, 1, 0,
|
||||||
(SCM time, SCM zone),
|
(SCM time, SCM zone),
|
||||||
"Returns an object representing the broken down components of @var{time},\n"
|
"Returns an object representing the broken down components of @var{time},\n"
|
||||||
|
@ -363,15 +362,13 @@ SCM_DEFINE (scm_localtime, "localtime", 1, 1, 0,
|
||||||
{
|
{
|
||||||
const char *ptr;
|
const char *ptr;
|
||||||
|
|
||||||
/* copy zone name before calling gmtime or tzset. */
|
/* copy zone name before calling gmtime or restoring zone. */
|
||||||
#ifdef HAVE_TM_ZONE
|
#if defined (HAVE_TM_ZONE)
|
||||||
ptr = ltptr->tm_zone;
|
ptr = ltptr->tm_zone;
|
||||||
#else
|
#elif defined (HAVE_TZNAME)
|
||||||
# ifdef HAVE_TZNAME
|
|
||||||
ptr = tzname[ (ltptr->tm_isdst == 1) ? 1 : 0 ];
|
ptr = tzname[ (ltptr->tm_isdst == 1) ? 1 : 0 ];
|
||||||
#else
|
#else
|
||||||
SCM_MISC_ERROR ("Not fully implemented on this platform",_EOL);
|
ptr = "";
|
||||||
# endif
|
|
||||||
#endif
|
#endif
|
||||||
zname = SCM_MUST_MALLOC (strlen (ptr) + 1);
|
zname = SCM_MUST_MALLOC (strlen (ptr) + 1);
|
||||||
strcpy (zname, ptr);
|
strcpy (zname, ptr);
|
||||||
|
@ -498,16 +495,13 @@ SCM_DEFINE (scm_mktime, "mktime", 1, 1, 0,
|
||||||
{
|
{
|
||||||
const char *ptr;
|
const char *ptr;
|
||||||
|
|
||||||
/* copy zone name before calling gmtime or tzset. */
|
/* copy zone name before calling gmtime or restoring the zone. */
|
||||||
#ifdef HAVE_TM_ZONE
|
#if defined (HAVE_TM_ZONE)
|
||||||
ptr = lt.tm_zone;
|
ptr = lt.tm_zone;
|
||||||
#else
|
#elif defined (HAVE_TZNAME)
|
||||||
# ifdef HAVE_TZNAME
|
|
||||||
ptr = tzname[ (lt.tm_isdst == 1) ? 1 : 0 ];
|
ptr = tzname[ (lt.tm_isdst == 1) ? 1 : 0 ];
|
||||||
#else
|
#else
|
||||||
scm_misc_error (s_mktime, "Not fully implemented on this platform",
|
ptr = "";
|
||||||
SCM_EOL);
|
|
||||||
# endif
|
|
||||||
#endif
|
#endif
|
||||||
zname = SCM_MUST_MALLOC (strlen (ptr) + 1);
|
zname = SCM_MUST_MALLOC (strlen (ptr) + 1);
|
||||||
strcpy (zname, ptr);
|
strcpy (zname, ptr);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue