[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.7-20-gb194b5
From: |
Andy Wingo |
Subject: |
[Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.7-20-gb194b59 |
Date: |
Thu, 10 Jan 2013 16:31:02 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".
http://git.savannah.gnu.org/cgit/guile.git/commit/?id=b194b59fa10574868f7b1663a1f2d447baa18c5e
The branch, stable-2.0 has been updated
via b194b59fa10574868f7b1663a1f2d447baa18c5e (commit)
via 921cd222b992f719dc870239bc196688b8d3d507 (commit)
from 03a2f59851ff9e9ae751c92c5608ef2a197c4938 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit b194b59fa10574868f7b1663a1f2d447baa18c5e
Author: Andy Wingo <address@hidden>
Date: Thu Jan 10 17:30:38 2013 +0100
fix ice-9/slib
* module/ice-9/slib.scm: Change to just load up slib.init directly. The
recently submitted patch to slib-discuss and guile-user should make
this work correctly.
commit 921cd222b992f719dc870239bc196688b8d3d507
Author: Andy Wingo <address@hidden>
Date: Thu Jan 10 16:01:06 2013 +0100
deprecate SCM_CHAR_CODE_LIMIT and char-code-limit
* libguile/__scm.h:
* libguile/deprecated.h (SCM_CHAR_CODE_LIMIT): Move declaration here
from __scm.h.
* libguile/feature.c:
* module/ice-9/deprecated.scm (char-code-limit): Move definition here.
* test-suite/tests/regexp.test: Update to not use char-code-limit.
-----------------------------------------------------------------------
Summary of changes:
doc/guile-api.alist | 1 -
libguile/__scm.h | 8 +-------
libguile/deprecated.h | 10 +++++++++-
libguile/feature.c | 4 +---
module/ice-9/deprecated.scm | 7 ++++++-
module/ice-9/slib.scm | 37 ++++++++++++++-----------------------
test-suite/tests/regexp.test | 23 ++++++++++++-----------
7 files changed, 43 insertions(+), 47 deletions(-)
diff --git a/doc/guile-api.alist b/doc/guile-api.alist
index 5f73cae..5830c91 100644
--- a/doc/guile-api.alist
+++ b/doc/guile-api.alist
@@ -466,7 +466,6 @@
(char-ci=? (groups Scheme) (scan-data "#<primitive-procedure char-ci=?>"))
(char-ci>=? (groups Scheme) (scan-data "#<primitive-procedure char-ci>=?>"))
(char-ci>? (groups Scheme) (scan-data "#<primitive-procedure char-ci>?>"))
-(char-code-limit (groups Scheme) (scan-data ""))
(char-downcase (groups Scheme) (scan-data "#<primitive-procedure
char-downcase>"))
(char-is-both? (groups Scheme) (scan-data "#<primitive-procedure
char-is-both?>"))
(char-lower-case? (groups Scheme) (scan-data "#<primitive-procedure
char-lower-case?>"))
diff --git a/libguile/__scm.h b/libguile/__scm.h
index 1c20bd7..47ed12b 100644
--- a/libguile/__scm.h
+++ b/libguile/__scm.h
@@ -4,7 +4,7 @@
#define SCM___SCM_H
/* Copyright (C) 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2006,
- * 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+ * 2007, 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@@ -436,12 +436,6 @@
# define SCM_LONG_BIT (SCM_CHAR_BIT * sizeof (long) / sizeof (char))
#endif
-#ifdef UCHAR_MAX
-# define SCM_CHAR_CODE_LIMIT (UCHAR_MAX + 1L)
-#else
-# define SCM_CHAR_CODE_LIMIT 256L
-#endif
-
#define SCM_I_UTYPE_MAX(type) ((type)-1)
#define SCM_I_TYPE_MAX(type,umax) ((type)((umax)/2))
#define SCM_I_TYPE_MIN(type,umax) (-((type)((umax)/2))-1)
diff --git a/libguile/deprecated.h b/libguile/deprecated.h
index ae0891f..de85c6f 100644
--- a/libguile/deprecated.h
+++ b/libguile/deprecated.h
@@ -5,7 +5,7 @@
#ifndef SCM_DEPRECATED_H
#define SCM_DEPRECATED_H
-/* Copyright (C) 2003,2004, 2005, 2006, 2007, 2009, 2010, 2011, 2012 Free
Software Foundation, Inc.
+/* Copyright (C) 2003,2004, 2005, 2006, 2007, 2009, 2010, 2011, 2012, 2013
Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@@ -839,6 +839,14 @@ SCM_DEPRECATED SCM scm_struct_vtable_tag (SCM handle);
+#ifdef UCHAR_MAX
+# define SCM_CHAR_CODE_LIMIT (UCHAR_MAX + 1L)
+#else
+# define SCM_CHAR_CODE_LIMIT 256L
+#endif
+
+
+
void scm_i_init_deprecated (void);
#endif
diff --git a/libguile/feature.c b/libguile/feature.c
index f3bddc7..4646975 100644
--- a/libguile/feature.c
+++ b/libguile/feature.c
@@ -1,5 +1,5 @@
/* Copyright (C) 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
- * 2006, 2007, 2009, 2011 Free Software Foundation, Inc.
+ * 2006, 2007, 2009, 2011, 2013 Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
@@ -123,8 +123,6 @@ scm_init_feature()
scm_add_feature ("threads");
#endif
- scm_c_define ("char-code-limit", scm_from_int (SCM_CHAR_CODE_LIMIT));
-
#include "libguile/feature.x"
}
diff --git a/module/ice-9/deprecated.scm b/module/ice-9/deprecated.scm
index 9d80cfe..3d40193 100644
--- a/module/ice-9/deprecated.scm
+++ b/module/ice-9/deprecated.scm
@@ -70,7 +70,8 @@
read-hash-procedures
process-define-module
fluid-let-syntax
- set-system-module!))
+ set-system-module!
+ char-code-limit))
;;;; Deprecated definitions.
@@ -896,3 +897,7 @@ it.")
(issue-deprecation-warning
"`module-eval-closure' is deprecated. Use module-variable or
module-define! instead.")
(standard-eval-closure m)))
+
+;; Legacy definition. We can't make it identifier-syntax yet though,
+;; because compiled code might rely on it.
+(define char-code-limit 256)
diff --git a/module/ice-9/slib.scm b/module/ice-9/slib.scm
index 78c734e..7664180 100644
--- a/module/ice-9/slib.scm
+++ b/module/ice-9/slib.scm
@@ -1,6 +1,6 @@
;;;; slib.scm --- definitions needed to get SLIB to work with Guile
;;;;
-;;;; Copyright (C) 1997, 1998, 2000, 2001, 2002, 2003, 2004, 2006, 2007 Free
Software Foundation, Inc.
+;;;; Copyright (C) 1997, 1998, 2000, 2001, 2002, 2003, 2004, 2006, 2007, 2013
Free Software Foundation, Inc.
;;;;
;;;; This library is free software; you can redistribute it and/or
;;;; modify it under the terms of the GNU Lesser General Public
@@ -16,27 +16,18 @@
;;;; License along with this library; if not, write to the Free Software
;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
USA
;;;;
-(define-module (ice-9 slib)
- :export (slib:load slib:load-source defmacro:load
- implementation-vicinity library-vicinity home-vicinity
- scheme-implementation-type scheme-implementation-version
- output-port-width output-port-height array-indexes
- make-random-state
- -1+ <? <=? =? >? >=?
- require slib:error slib:exit slib:warn slib:eval
- defmacro:eval logical:logand logical:logior logical:logxor
- logical:lognot logical:ash logical:logcount logical:integer-length
- logical:bit-extract logical:integer-expt logical:ipow-by-squaring
- slib:eval-load slib:tab slib:form-feed difftime offset-time
- software-type)
- :no-backtrace)
-
-;; Initialize SLIB.
-(load-from-path "slib/guile.init")
+;;; Look for slib.init in the $datadir, in /usr/share, and finally in
+;;; the load path. It's not usually in the load path on common distros,
+;;; but it could be if the user put it there. The init file takes care
+;;; of defining the module.
-;; SLIB redefines a few core symbols based on their default definition.
-;; Thus, we only replace them at this point so that their previous definition
-;; is visible when `guile.init' is loaded.
-(module-replace! (current-module)
- '(delete-file open-file provide provided? system))
+(let ((try-load (lambda (dir)
+ (let ((init (string-append dir "/slib/guile.init")))
+ (and (file-exists? init)
+ (begin
+ (load init)
+ #t))))))
+ (or (try-load (assq-ref %guile-build-info 'datadir))
+ (try-load "/usr/share")
+ (load-from-path "slib/guile.init")))
diff --git a/test-suite/tests/regexp.test b/test-suite/tests/regexp.test
index d549df2..b5c59f0 100644
--- a/test-suite/tests/regexp.test
+++ b/test-suite/tests/regexp.test
@@ -2,7 +2,7 @@
;;;; Jim Blandy <address@hidden> --- September 1999
;;;;
;;;; Copyright (C) 1999, 2004, 2006, 2007, 2008, 2009, 2010,
-;;;; 2012 Free Software Foundation, Inc.
+;;;; 2012, 2013 Free Software Foundation, Inc.
;;;;
;;;; This library is free software; you can redistribute it and/or
;;;; modify it under the terms of the GNU Lesser General Public
@@ -171,10 +171,10 @@
(let ((lst `((regexp/basic ,regexp/basic)
(regexp/extended ,regexp/extended)))
- ;; string of all characters, except #\nul which doesn't work because
- ;; it's the usual end-of-string for the underlying C regexec()
- (allchars (list->string (map integer->char
- (cdr (iota char-code-limit))))))
+ ;; String of all latin-1 characters, except #\nul which doesn't
+ ;; work because it's the usual end-of-string for the underlying
+ ;; C regexec().
+ (allchars (list->string (map integer->char (cdr (iota 256))))))
(for-each
(lambda (elem)
(let ((name (car elem))
@@ -182,9 +182,9 @@
(with-test-prefix name
- ;; try on each individual character, except #\nul
+ ;; Try on each individual latin-1 character, except #\nul.
(do ((i 1 (1+ i)))
- ((>= i char-code-limit))
+ ((>= i 256))
(let* ((c (integer->char i))
(s (string c)))
(pass-if (list "char" i (format #f "~s ~s" c s))
@@ -194,11 +194,12 @@
(and (= 0 (match:start m))
(= 1 (match:end m))))))))
- ;; try on pattern "aX" where X is each character, except #\nul
- ;; this exposes things like "?" which are special only when they
- ;; follow a pattern to repeat or whatever ("a" in this case)
+ ;; Try on pattern "aX" where X is each latin-1 character,
+ ;; except #\nul. This exposes things like "?" which are
+ ;; special only when they follow a pattern to repeat or
+ ;; whatever ("a" in this case).
(do ((i 1 (1+ i)))
- ((>= i char-code-limit))
+ ((>= i 256))
(let* ((c (integer->char i))
(s (string #\a c))
(q (with-unicode (regexp-quote s))))
hooks/post-receive
--
GNU Guile
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Guile-commits] GNU Guile branch, stable-2.0, updated. v2.0.7-20-gb194b59,
Andy Wingo <=