diff options
author | Dirk Herrmann <dirk@dirk-herrmanns-seiten.de> | 2001-05-14 16:38:08 +0000 |
---|---|---|
committer | Dirk Herrmann <dirk@dirk-herrmanns-seiten.de> | 2001-05-14 16:38:08 +0000 |
commit | 5cd06d5eaac5a96af1e8d65dbf06131411fe9a6c (patch) | |
tree | b192529ad0d3a9b151373a200760d72a38800bbd | |
parent | 928f20fb8730fa4e0c61c8aa44761717c349dcc7 (diff) | |
download | guile-5cd06d5eaac5a96af1e8d65dbf06131411fe9a6c.tar.gz |
* Deprecated some definitions.
* Minor fixes.
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | NEWS | 16 | ||||
-rw-r--r-- | RELEASE | 3 | ||||
-rw-r--r-- | configure.in | 3 | ||||
-rw-r--r-- | ice-9/ChangeLog | 5 | ||||
-rw-r--r-- | ice-9/boot-9.scm | 36 | ||||
-rw-r--r-- | libguile/ChangeLog | 7 | ||||
-rw-r--r-- | libguile/deprecation.c | 2 | ||||
-rw-r--r-- | libguile/deprecation.h | 8 |
9 files changed, 59 insertions, 25 deletions
@@ -1,3 +1,7 @@ +2001-05-14 Dirk Herrmann <D.Herrmann@tu-bs.de> + + * configure.in (SCM_DEBUG_DEPRECATED): Always defined. + 2001-05-13 Thien-Thi Nguyen <ttn@revel.glug.org> * AUTHORS (Martin Grabmueller, Thien-Thi Nguyen): Update. @@ -603,6 +603,22 @@ Return the argument. Use `identity' instead. +** Deprecated: -1+ + +Use `1-' instead. + +** Deprecated: return-it + +Use `noop' instead. + +** Deprecated: string-character-length + +Use `string-length' instead. + +** Deprecated: flags + +Use `logior' instead. + ** Deprecated: close-all-ports-except. This was intended for closing ports in a child process after a fork, @@ -40,7 +40,8 @@ After signal handling and threading have been fixed: gc.c: scm_remember string.c: scm_makstr - remove deprecated procedures: - boot-9.scm: eval-in-module, id + boot-9.scm: eval-in-module, id, -1+, return-it, string-character-length, + flags - remove deprecated macros: SCM_OUTOFRANGE, SCM_NALLOC, SCM_HUP_SIGNAL, SCM_INT_SIGNAL, SCM_FPE_SIGNAL, SCM_BUS_SIGNAL, SCM_SEGV_SIGNAL, SCM_ALRM_SIGNAL, SCM_GC_SIGNAL, SCM_TICK_SIGNAL, SCM_SIG_ORD, diff --git a/configure.in b/configure.in index dbe5bbd28..143aa4d86 100644 --- a/configure.in +++ b/configure.in @@ -100,7 +100,7 @@ AC_ARG_ENABLE(deprecated, [ --disable-deprecated omit deprecated features [no]]) if test "$enable_deprecated" = no; then - AC_DEFINE(SCM_DEBUG_DEPRECATED) + AC_DEFINE(SCM_DEBUG_DEPRECATED, 1) else if test "$enable_deprecated" = yes || test "$enable_deprecated" = ""; then warn_default=summary @@ -109,6 +109,7 @@ else else warn_default=$enable_deprecated fi + AC_DEFINE(SCM_DEBUG_DEPRECATED, 0) AC_DEFINE_UNQUOTED(GUILE_WARN_DEPRECATED_DEFAULT, "$warn_default") fi diff --git a/ice-9/ChangeLog b/ice-9/ChangeLog index 676d4959c..6adf45be1 100644 --- a/ice-9/ChangeLog +++ b/ice-9/ChangeLog @@ -1,3 +1,8 @@ +2001-05-14 Dirk Herrmann <D.Herrmann@tu-bs.de> + + * boot-9.scm (-1+, return-it, string-character-length, flags): + Deprecated. + 2001-05-11 Martin Grabmueller <mgrabmue@cs.tu-berlin.de> * boot-9.scm: Added `cond-expand' (SRFI-0) for portable feature diff --git a/ice-9/boot-9.scm b/ice-9/boot-9.scm index fa6e377a6..909346062 100644 --- a/ice-9/boot-9.scm +++ b/ice-9/boot-9.scm @@ -107,18 +107,22 @@ (define (identity x) x) (define (1+ n) (+ n 1)) -(define (-1+ n) (+ n -1)) -(define 1- -1+) -(define return-it noop) +(define (1- n) (+ n -1)) (define (and=> value procedure) (and value (procedure value))) (define (make-hash-table k) (make-vector k '())) (begin-deprecated (define (id x) (issue-deprecation-warning "`id' is deprecated. Use `identity' instead.") - (identity x))) - -;;; apply-to-args is functionally redunant with apply and, worse, + (identity x)) + (define (-1+ n) + (issue-deprecation-warning "`-1+' is deprecated. Use `1-' instead.") + (1- n)) + (define (return-it . args) + (issue-deprecation-warning "`return-it' is deprecated. Use `noop' instead.") + (apply noop args))) + +;;; apply-to-args is functionally redundant with apply and, worse, ;;; is less general than apply since it only takes two arguments. ;;; ;;; On the other hand, apply-to-args is a syntacticly convenient way to @@ -145,18 +149,13 @@ (if (even? k) acc (proc acc x)) proc)))) -(define string-character-length string-length) - - - -;; A convenience function for combining flag bits. Like logior, but -;; handles the cases of 0 and 1 arguments. -;; -(define (flags . args) - (cond - ((null? args) 0) - ((null? (cdr args)) (car args)) - (else (apply logior args)))) +(begin-deprecated + (define (string-character-length s) + (issue-deprecation-warning "`string-character-length' is deprecated. Use `string-length' instead.") + (string-length s)) + (define (flags . args) + (issue-deprecation-warning "`flags' is deprecated. Use `logior' instead.") + (apply logior args))) ;;; {Symbol Properties} @@ -178,6 +177,7 @@ (symbol-pset! sym (delq! pair (symbol-pref sym)))))) ;;; {General Properties} +;;; ;; This is a more modern interface to properties. It will replace all ;; other property-like things eventually. diff --git a/libguile/ChangeLog b/libguile/ChangeLog index 47ac504ff..41f9a5755 100644 --- a/libguile/ChangeLog +++ b/libguile/ChangeLog @@ -1,3 +1,10 @@ +2001-05-14 Dirk Herrmann <D.Herrmann@tu-bs.de> + + * deprecation.c: Fixed copyright date. + + * deprecation.h (DEPRECATION_H, SCM_DEPRECATION_H): Renamed + DEPRECATION_H to SCM_DEPRECATION_H. + 2001-05-10 Thien-Thi Nguyen <ttn@revel.glug.org> * guile-doc-snarf.in: Update copyright. diff --git a/libguile/deprecation.c b/libguile/deprecation.c index 0dd44cb54..a8e2e6cab 100644 --- a/libguile/deprecation.c +++ b/libguile/deprecation.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1995,1996,1998,1999,2000,2001 Free Software Foundation, Inc. +/* Copyright (C) 2001 Free Software Foundation, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by diff --git a/libguile/deprecation.h b/libguile/deprecation.h index 663014387..aa75824f2 100644 --- a/libguile/deprecation.h +++ b/libguile/deprecation.h @@ -1,8 +1,8 @@ /* classes: h_files */ -#ifndef DEPRECATION_H -#define DEPRECATION_H -/* Copyright (C) 2001 Free Software Foundation, Inc. +#ifndef SCM_DEPRECATION_H +#define SCM_DEPRECATION_H +/* Copyright (C) 2001 Free Software Foundation, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -58,7 +58,7 @@ SCM scm_include_deprecated_features (void); void scm_init_deprecation (void); -#endif /* DEPRECATION_H */ +#endif /* SCM_DEPRECATION_H */ /* Local Variables: |