* list.c (scm_list_n): Add #if SCM_DEBUG_CELL_ACCESSES_P around
authorNeil Jerram <neil@ossau.uklinux.net>
Fri, 20 Feb 2004 22:04:24 +0000 (22:04 +0000)
committerNeil Jerram <neil@ossau.uklinux.net>
Fri, 20 Feb 2004 22:04:24 +0000 (22:04 +0000)
validation.

* read.c (scm_lreadparen): Removed.
(scm_lreadparen1): Renamed scm_i_lreadparen.

libguile/ChangeLog
libguile/list.c
libguile/read.c
libguile/read.h

index e7d61a6..68fbd2a 100644 (file)
@@ -1,3 +1,11 @@
+2004-02-20  Neil Jerram  <neil@ossau.uklinux.net>
+
+       * list.c (scm_list_n): Add #if SCM_DEBUG_CELL_ACCESSES_P around
+       validation.
+
+       * read.c (scm_lreadparen): Removed.
+       (scm_lreadparen1): Renamed scm_i_lreadparen.
+
 2004-02-20  Han-Wen Nienhuys   <hanwen@xs4all.nl>
 
        * list.c (scm_list_n): validate non-immediate arguments;
index e36797f..0088bb3 100644 (file)
@@ -90,9 +90,10 @@ scm_list_n (SCM elt, ...)
   var_start (foo, elt);
   while (! SCM_UNBNDP (elt))
     {
+#if (SCM_DEBUG_CELL_ACCESSES == 1)
       if (SCM_NIMP (elt))
        SCM_VALIDATE_CELL(elt, 0);
-      
+#endif      
       *pos = scm_cons (elt, SCM_EOL);
       pos = SCM_CDRLOC (*pos);
       elt = va_arg (foo, SCM);
index 10e8d82..8a90b33 100644 (file)
@@ -298,7 +298,7 @@ skip_scsh_block_comment (SCM port)
 
 
 static SCM scm_get_hash_procedure(int c);
-static SCM scm_lreadparen1 (SCM *, SCM, char *, SCM *, char);
+static SCM scm_i_lreadparen (SCM *, SCM, char *, SCM *, char);
 
 static char s_list[]="list";
 static char s_vector[]="vector";
@@ -322,7 +322,7 @@ scm_lreadr (SCM *tok_buf, SCM port, SCM *copy)
     case '(':
       return SCM_RECORD_POSITIONS_P
        ? scm_lreadrecparen (tok_buf, port, s_list, copy)
-       : scm_lreadparen1 (tok_buf, port, s_list, copy, ')');
+       : scm_i_lreadparen (tok_buf, port, s_list, copy, ')');
     case ')':
       scm_input_error (FUNC_NAME, port,"unexpected \")\"", SCM_EOL);
       goto tryagain;
@@ -331,7 +331,7 @@ scm_lreadr (SCM *tok_buf, SCM port, SCM *copy)
     case '[':
       if (SCM_ELISP_VECTORS_P)
        {
-         p = scm_lreadparen1 (tok_buf, port, s_vector, copy, ']');
+         p = scm_i_lreadparen (tok_buf, port, s_vector, copy, ']');
          return SCM_NULLP (p) ? scm_nullvect : scm_vector (p);
        }
       goto read_token;
@@ -395,7 +395,7 @@ scm_lreadr (SCM *tok_buf, SCM port, SCM *copy)
       switch (c)
        {
        case '(':
-         p = scm_lreadparen1 (tok_buf, port, s_vector, copy, ')');
+         p = scm_i_lreadparen (tok_buf, port, s_vector, copy, ')');
          return SCM_NULLP (p) ? scm_nullvect : scm_vector (p);
 
        case 't':
@@ -723,15 +723,9 @@ scm_read_token (int ic, SCM *tok_buf, SCM port, int weird)
 _Pragma ("opt");               /* # pragma _CRI opt */
 #endif
 
-SCM 
-scm_lreadparen (SCM *tok_buf, SCM port, char *name, SCM *copy)
-{
-  return scm_lreadparen1 (tok_buf, port, name, copy, ')');
-}
-
 static SCM 
-scm_lreadparen1 (SCM *tok_buf, SCM port, char *name, SCM *copy, char term_char)
-#define FUNC_NAME "scm_lreadparen"
+scm_i_lreadparen (SCM *tok_buf, SCM port, char *name, SCM *copy, char term_char)
+#define FUNC_NAME "scm_i_lreadparen"
 {
   SCM tmp;
   SCM tl;
index 2f72514..70f6521 100644 (file)
@@ -70,7 +70,6 @@ SCM_API int scm_flush_ws (SCM port, const char *eoferr);
 SCM_API int scm_casei_streq (char * s1, char * s2);
 SCM_API SCM scm_lreadr (SCM * tok_buf, SCM port, SCM *copy);
 SCM_API size_t scm_read_token (int ic, SCM * tok_buf, SCM port, int weird);
-SCM_API SCM scm_lreadparen (SCM * tok_buf, SCM port, char *name, SCM *copy);
 SCM_API SCM scm_lreadrecparen (SCM * tok_buf, SCM port, char *name, SCM *copy);
 SCM_API SCM scm_read_hash_extend (SCM chr, SCM proc);
 SCM_API void scm_init_read (void);