* Deprecated some definitions.
authorDirk Herrmann <dirk@dirk-herrmanns-seiten.de>
Mon, 14 May 2001 16:38:08 +0000 (16:38 +0000)
committerDirk Herrmann <dirk@dirk-herrmanns-seiten.de>
Mon, 14 May 2001 16:38:08 +0000 (16:38 +0000)
* Minor fixes.

ChangeLog
NEWS
RELEASE
configure.in
ice-9/ChangeLog
ice-9/boot-9.scm
libguile/ChangeLog
libguile/deprecation.c
libguile/deprecation.h

index d492435..4366dd4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -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.
diff --git a/NEWS b/NEWS
index 425a3c6..2f666cc 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -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,
diff --git a/RELEASE b/RELEASE
index 36a494a..09ce29a 100644 (file)
--- a/RELEASE
+++ b/RELEASE
@@ -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, 
index dbe5bbd..143aa4d 100644 (file)
@@ -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
 
index 676d495..6adf45b 100644 (file)
@@ -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
index fa6e377..9093460 100644 (file)
 
 (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
                                (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)))
 
 \f
 ;;; {Symbol Properties}
        (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.
index 47ac504..41f9a57 100644 (file)
@@ -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.
index 0dd44cb..a8e2e6c 100644 (file)
@@ -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
index 6630143..aa75824 100644 (file)
@@ -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: