[uim-commit] r3039 - branches/r5rs/sigscheme/src

yamaken at freedesktop.org yamaken at freedesktop.org
Sun Jan 29 23:38:53 PST 2006


Author: yamaken
Date: 2006-01-29 23:38:50 -0800 (Sun, 29 Jan 2006)
New Revision: 3039

Modified:
   branches/r5rs/sigscheme/src/module-nonstd.c
   branches/r5rs/sigscheme/src/sigscheme.c
   branches/r5rs/sigscheme/src/sigscheme.h
Log:
* sigscheme/src/sigscheme.c
  - (scm_initialize_internal): Provide "64bit-addr" if (SCM_PTR_BITS
    == 64)
* sigscheme/src/sigscheme.h
  - (scm_p_least_fixnum, scm_p_greatest_fixnum): New function decl
* sigscheme/src/module-nonstd.c
  - (scm_p_least_fixnum, scm_p_greatest_fixnum): New function


Modified: branches/r5rs/sigscheme/src/module-nonstd.c
===================================================================
--- branches/r5rs/sigscheme/src/module-nonstd.c	2006-01-30 07:06:24 UTC (rev 3038)
+++ branches/r5rs/sigscheme/src/module-nonstd.c	2006-01-30 07:38:50 UTC (rev 3039)
@@ -106,6 +106,24 @@
     return MAKE_BOOL(ref != SCM_INVALID_REF || SCM_SYMBOL_BOUNDP(sym));
 }
 
+/* SRFI-77 compatible */
+ScmObj
+scm_p_least_fixnum(void)
+{
+    DECLARE_FUNCTION("least-fixnum", procedure_fixed_0);
+
+    return MAKE_INT(SCM_INT_MIN);
+}
+
+/* SRFI-77 compatible */
+ScmObj
+scm_p_greatest_fixnum(void)
+{
+    DECLARE_FUNCTION("greatest-fixnum", procedure_fixed_0);
+
+    return MAKE_INT(SCM_INT_MAX);
+}
+
 /* SIOD compatible */
 ScmObj
 scm_p_load_path(void)

Modified: branches/r5rs/sigscheme/src/sigscheme.c
===================================================================
--- branches/r5rs/sigscheme/src/sigscheme.c	2006-01-30 07:06:24 UTC (rev 3038)
+++ branches/r5rs/sigscheme/src/sigscheme.c	2006-01-30 07:38:50 UTC (rev 3039)
@@ -155,6 +155,11 @@
 #if SCM_HAS_IMMEDIATE_NUMBER_ONLY
     scm_provide(CONST_STRING("immediate-number-only"));
 #endif
+    /* Since SCM_SAL_PTR_BITS may use sizeof() instead of autoconf SIZEOF
+     * macro, #if is not safe here. */
+    if (SCM_PTR_BITS == 64)
+        scm_provide(CONST_STRING("64bit-addr"));
+
     scm_initialized = scm_true;
 }
 

Modified: branches/r5rs/sigscheme/src/sigscheme.h
===================================================================
--- branches/r5rs/sigscheme/src/sigscheme.h	2006-01-30 07:06:24 UTC (rev 3038)
+++ branches/r5rs/sigscheme/src/sigscheme.h	2006-01-30 07:38:50 UTC (rev 3039)
@@ -1322,6 +1322,8 @@
 #if SCM_USE_NONSTD_FEATURES
 void scm_initialize_nonstd_features(void);
 ScmObj scm_p_symbol_boundp(ScmObj sym, ScmObj rest);
+ScmObj scm_p_least_fixnum(void);
+ScmObj scm_p_greatest_fixnum(void);
 ScmObj scm_p_load_path(void);
 void scm_require(const char *filename);
 ScmObj scm_p_require(ScmObj filename);



More information about the uim-commit mailing list