diff options
Diffstat (limited to 'module')
-rw-r--r-- | module/Makefile.am | 3 | ||||
-rw-r--r-- | module/ice-9/debug.scm | 25 | ||||
-rw-r--r-- | module/ice-9/deprecated.scm | 77 | ||||
-rw-r--r-- | module/ice-9/format.scm | 24 | ||||
-rw-r--r-- | module/ice-9/mapping.scm | 118 | ||||
-rw-r--r-- | module/ice-9/syncase.scm | 37 | ||||
-rw-r--r-- | module/oop/goops.scm | 37 | ||||
-rw-r--r-- | module/statprof.scm | 49 | ||||
-rw-r--r-- | module/texinfo/reflection.scm | 7 | ||||
-rw-r--r-- | module/web/client.scm | 24 | ||||
-rw-r--r-- | module/web/uri.scm | 9 |
11 files changed, 4 insertions, 406 deletions
diff --git a/module/Makefile.am b/module/Makefile.am index d5896bdd8..8a8eab583 100644 --- a/module/Makefile.am +++ b/module/Makefile.am @@ -54,7 +54,6 @@ SOURCES = \ ice-9/common-list.scm \ ice-9/control.scm \ ice-9/curried-definitions.scm \ - ice-9/debug.scm \ ice-9/deprecated.scm \ ice-9/documentation.scm \ ice-9/eval-string.scm \ @@ -75,7 +74,6 @@ SOURCES = \ ice-9/list.scm \ ice-9/local-eval.scm \ ice-9/ls.scm \ - ice-9/mapping.scm \ ice-9/match.scm \ ice-9/networking.scm \ ice-9/null.scm \ @@ -113,7 +111,6 @@ SOURCES = \ ice-9/streams.scm \ ice-9/string-fun.scm \ ice-9/suspendable-ports.scm \ - ice-9/syncase.scm \ ice-9/textual-ports.scm \ ice-9/threads.scm \ ice-9/time.scm \ diff --git a/module/ice-9/debug.scm b/module/ice-9/debug.scm deleted file mode 100644 index 380b04595..000000000 --- a/module/ice-9/debug.scm +++ /dev/null @@ -1,25 +0,0 @@ -;;;; Copyright (C) 1996, 1997, 1998, 1999, 2001, 2006, 2010 Free Software Foundation -;;;; -;;;; This library is free software; you can redistribute it and/or -;;;; modify it under the terms of the GNU Lesser General Public -;;;; License as published by the Free Software Foundation; either -;;;; version 3 of the License, or (at your option) any later version. -;;;; -;;;; This library is distributed in the hope that it will be useful, -;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -;;;; Lesser General Public License for more details. -;;;; -;;;; You should have received a copy of the GNU Lesser General Public -;;;; License along with this library; if not, write to the Free Software -;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -;;;; -;;;; The author can be reached at djurfeldt@nada.kth.se -;;;; Mikael Djurfeldt, SANS/NADA KTH, 10044 STOCKHOLM, SWEDEN -;;;; - - -(define-module (ice-9 debug)) - -(issue-deprecation-warning - "(ice-9 debug) is deprecated. Use (system vm trace) for tracing.") diff --git a/module/ice-9/deprecated.scm b/module/ice-9/deprecated.scm index 2f41686ac..597ca8b4d 100644 --- a/module/ice-9/deprecated.scm +++ b/module/ice-9/deprecated.scm @@ -15,79 +15,4 @@ ;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA ;;;; -(define-module (ice-9 deprecated) - #:use-module ((ice-9 threads) #:prefix threads:)) - -(define-syntax-rule (define-deprecated var msg exp) - (begin - (define-syntax var - (lambda (x) - (issue-deprecation-warning msg) - (syntax-case x () - ((id arg (... ...)) #'(let ((x id)) (x arg (... ...)))) - (id (identifier? #'id) #'exp)))) - (export var))) - -(define-deprecated _IONBF - "`_IONBF' is deprecated. Use the symbol 'none instead." - 'none) -(define-deprecated _IOLBF - "`_IOLBF' is deprecated. Use the symbol 'line instead." - 'line) -(define-deprecated _IOFBF - "`_IOFBF' is deprecated. Use the symbol 'block instead." - 'block) - -(define-syntax define-deprecated/threads - (lambda (stx) - (define (threads-name id) - (datum->syntax id (symbol-append 'threads: (syntax->datum id)))) - (syntax-case stx () - ((_ name) - (with-syntax ((name* (threads-name #'name)) - (warning (string-append - "Import (ice-9 threads) to have access to `" - (symbol->string (syntax->datum #'name)) "'."))) - #'(define-deprecated name warning name*)))))) - -(define-syntax-rule (define-deprecated/threads* name ...) - (begin (define-deprecated/threads name) ...)) - -(define-deprecated/threads* - call-with-new-thread - yield - cancel-thread - join-thread - thread? - make-mutex - make-recursive-mutex - lock-mutex - try-mutex - unlock-mutex - mutex? - mutex-owner - mutex-level - mutex-locked? - make-condition-variable - wait-condition-variable - signal-condition-variable - broadcast-condition-variable - condition-variable? - current-thread - all-threads - thread-exited? - total-processor-count - current-processor-count) - -(define-public make-dynamic-state - (case-lambda - (() - (issue-deprecation-warning - "`(make-dynamic-state)' is deprecated; use `(current-dynamic-state)' -instead.") - (current-dynamic-state)) - ((parent) - (issue-deprecation-warning - "`(make-dynamic-state PARENT)' is deprecated; now that reified -dynamic state objects are themselves copies, just use PARENT directly.") - parent))) +(define-module (ice-9 deprecated)) diff --git a/module/ice-9/format.scm b/module/ice-9/format.scm index 1ef4cb5ef..e7258a1e2 100644 --- a/module/ice-9/format.scm +++ b/module/ice-9/format.scm @@ -45,11 +45,6 @@ ((not destination) (open-output-string)) ((boolean? destination) (current-output-port)) ; boolean but not false ((output-port? destination) destination) - ((number? destination) - (issue-deprecation-warning - "Passing a number to format as the port is deprecated." - "Pass (current-error-port) instead.") - (current-error-port)) (else (error "format: bad destination `~a'" destination)))) @@ -1603,24 +1598,5 @@ (close-port port) str))))))) -(begin-deprecated - (set! format - (let ((format format)) - (case-lambda - ((destination format-string . args) - (if (string? destination) - (begin - (issue-deprecation-warning - "Omitting the destination on a call to format is deprecated." - "Pass #f as the destination, before the format string.") - (apply format #f destination format-string args)) - (apply format destination format-string args))) - ((deprecated-format-string-only) - (issue-deprecation-warning - "Omitting the destination port on a call to format is deprecated." - "Pass #f as the destination port, before the format string.") - (format #f deprecated-format-string-only)))))) - - ;; Thanks to Shuji Narazaki (module-set! the-root-module 'format format) diff --git a/module/ice-9/mapping.scm b/module/ice-9/mapping.scm deleted file mode 100644 index bd4dbfbd3..000000000 --- a/module/ice-9/mapping.scm +++ /dev/null @@ -1,118 +0,0 @@ -;;; installed-scm-file - -;;;; Copyright (C) 1996, 2001, 2006, 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 as published by the Free Software Foundation; either -;;;; version 3 of the License, or (at your option) any later version. -;;;; -;;;; This library is distributed in the hope that it will be useful, -;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -;;;; Lesser General Public License for more details. -;;;; -;;;; You should have received a copy of the GNU Lesser General Public -;;;; 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 mapping) - :use-module (ice-9 poe) - :export (mapping-hooks-type make-mapping-hooks mapping-hooks? - mapping-hooks-get-handle mapping-hooks-create-handle - mapping-hooks-remove mapping-type make-mapping mapping? - mapping-hooks mapping-data set-mapping-hooks! set-mapping-data! - mapping-get-handle mapping-create-handle! mapping-remove! - mapping-ref mapping-set! hash-table-mapping-hooks - make-hash-table-mapping hash-table-mapping)) - -(issue-deprecation-warning - "(ice-9 mapping) is deprecated. Use srfi-69 or rnrs hash tables instead.") - -(define mapping-hooks-type (make-record-type 'mapping-hooks '(get-handle - create-handle - remove))) - - -(define make-mapping-hooks (perfect-funcq 17 (record-constructor mapping-hooks-type))) -(define mapping-hooks? (record-predicate mapping-hooks-type)) -(define mapping-hooks-get-handle (record-accessor mapping-hooks-type 'get-handle)) -(define mapping-hooks-create-handle (record-accessor mapping-hooks-type 'create-handle)) -(define mapping-hooks-remove (record-accessor mapping-hooks-type 'remove)) - -(define mapping-type (make-record-type 'mapping '(hooks data))) -(define make-mapping (record-constructor mapping-type)) -(define mapping? (record-predicate mapping-type)) -(define mapping-hooks (record-accessor mapping-type 'hooks)) -(define mapping-data (record-accessor mapping-type 'data)) -(define set-mapping-hooks! (record-modifier mapping-type 'hooks)) -(define set-mapping-data! (record-modifier mapping-type 'data)) - -(define (mapping-get-handle map key) - ((mapping-hooks-get-handle (mapping-hooks map)) map key)) -(define (mapping-create-handle! map key init) - ((mapping-hooks-create-handle (mapping-hooks map)) map key init)) -(define (mapping-remove! map key) - ((mapping-hooks-remove (mapping-hooks map)) map key)) - -(define* (mapping-ref map key #:optional dflt) - (cond - ((mapping-get-handle map key) => cdr) - (else dflt))) - -(define (mapping-set! map key val) - (set-cdr! (mapping-create-handle! map key #f) val)) - - - -(define hash-table-mapping-hooks - (let ((wrap (lambda (proc) (lambda (1st . rest) (apply proc (mapping-data 1st) rest))))) - - (perfect-funcq 17 - (lambda (hash-proc assoc-proc) - (let ((procs (list hash-proc assoc-proc))) - (cond - ((equal? procs `(,hashq ,assq)) - (make-mapping-hooks (wrap hashq-get-handle) - (wrap hashq-create-handle!) - (wrap hashq-remove!))) - ((equal? procs `(,hashv ,assv)) - (make-mapping-hooks (wrap hashv-get-handle) - (wrap hashv-create-handle!) - (wrap hashv-remove!))) - ((equal? procs `(,hash ,assoc)) - (make-mapping-hooks (wrap hash-get-handle) - (wrap hash-create-handle!) - (wrap hash-remove!))) - (else - (make-mapping-hooks (wrap - (lambda (table key) - (hashx-get-handle hash-proc assoc-proc table key))) - (wrap - (lambda (table key init) - (hashx-create-handle! hash-proc assoc-proc table key init))) - (wrap - (lambda (table key) - (hashx-remove! hash-proc assoc-proc table key))))))))))) - -(define (make-hash-table-mapping table hash-proc assoc-proc) - (make-mapping (hash-table-mapping-hooks hash-proc assoc-proc) table)) - -(define* (hash-table-mapping #:optional (size 71) #:key - (hash-proc hash) - (assoc-proc - (or (assq-ref `((,hashq . ,assq) - (,hashv . ,assv) - (,hash . ,assoc)) - hash-proc) - (error 'hash-table-mapping - "Hash-procedure specified with no known assoc function." - hash-proc))) - (table-constructor - (lambda (len) (make-vector len '())))) - (make-hash-table-mapping (table-constructor size) - hash-proc - assoc-proc)) diff --git a/module/ice-9/syncase.scm b/module/ice-9/syncase.scm deleted file mode 100644 index 219803ef0..000000000 --- a/module/ice-9/syncase.scm +++ /dev/null @@ -1,37 +0,0 @@ -;;;; Copyright (C) 1997, 2000, 2001, 2002, 2003, 2006, 2010 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 as published by the Free Software Foundation; either -;;;; version 3 of the License, or (at your option) any later version. -;;;; -;;;; This library is distributed in the hope that it will be useful, -;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -;;;; Lesser General Public License for more details. -;;;; -;;;; You should have received a copy of the GNU Lesser General Public -;;;; 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 syncase) - ;; FIXME re-export other procs - #:export (datum->syntax-object syntax-object->datum - sc-expand)) - -(issue-deprecation-warning - "Syntax-case macros are now a part of Guile core; importing (ice-9 syncase) is no longer necessary.") - -(define datum->syntax-object datum->syntax) -(define syntax-object->datum syntax->datum) -(define sc-expand macroexpand) - -;;; Hack to make syncase macros work in the slib module -;; FIXME wingo is this still necessary? -;; (let ((m (nested-ref the-root-module '(%app modules ice-9 slib)))) -;; (if m -;; (set-object-property! (module-local-variable m 'define) -;; '*sc-expander* -;; '(define)))) diff --git a/module/oop/goops.scm b/module/oop/goops.scm index a46918062..c78d0bd3c 100644 --- a/module/oop/goops.scm +++ b/module/oop/goops.scm @@ -1188,39 +1188,6 @@ function." #f) (%class-slot-definition (class-of obj) slot-name have-slot no-slot)) -(begin-deprecated - (define (check-slot-args class obj slot-name) - (unless (eq? class (class-of obj)) - (scm-error 'wrong-type-arg #f "~S is not the class of ~S" - (list class obj) #f)) - (unless (symbol? slot-name) - (scm-error 'wrong-type-arg #f "Not a symbol: ~S" - (list slot-name) #f))) - - (define (slot-ref-using-class class obj slot-name) - (issue-deprecation-warning "slot-ref-using-class is deprecated. " - "Use slot-ref instead.") - (check-slot-args class obj slot-name) - (slot-ref obj slot-name)) - - (define (slot-set-using-class! class obj slot-name value) - (issue-deprecation-warning "slot-set-using-class! is deprecated. " - "Use slot-set! instead.") - (check-slot-args class obj slot-name) - (slot-set! obj slot-name value)) - - (define (slot-bound-using-class? class obj slot-name) - (issue-deprecation-warning "slot-bound-using-class? is deprecated. " - "Use slot-bound? instead.") - (check-slot-args class obj slot-name) - (slot-bound? obj slot-name)) - - (define (slot-exists-using-class? class obj slot-name) - (issue-deprecation-warning "slot-exists-using-class? is deprecated. " - "Use slot-exists? instead.") - (check-slot-args class obj slot-name) - (slot-exists? obj slot-name))) - @@ -3097,10 +3064,6 @@ var{initargs}." ;;; {SMOB and port classes} ;;; -(begin-deprecated - (define-public <arbiter> (find-subclass <top> '<arbiter>)) - (define-public <async> (find-subclass <top> '<async>))) - (define <promise> (find-subclass <top> '<promise>)) (define <thread> (find-subclass <top> '<thread>)) (define <mutex> (find-subclass <top> '<mutex>)) diff --git a/module/statprof.scm b/module/statprof.scm index 59a2f12d0..9f2179b06 100644 --- a/module/statprof.scm +++ b/module/statprof.scm @@ -65,7 +65,6 @@ statprof-display statprof-display-anomalies - statprof-display-anomolies ; Deprecated spelling. statprof-fetch-stacks statprof-fetch-call-tree @@ -677,11 +676,6 @@ statistics.@code{}" (format #t "Total time: ~A\n" (statprof-accumulated-time state)) (format #t "Sample count: ~A\n" (statprof-sample-count state))) -(define (statprof-display-anomolies) - (issue-deprecation-warning "statprof-display-anomolies is a misspelling. " - "Use statprof-display-anomalies instead.") - (statprof-display-anomalies)) - (define* (statprof-accumulated-time #:optional (state (existing-profiler-state))) "Returns the time accumulated during the last statprof run.@code{}" @@ -895,49 +889,6 @@ operation is somewhat expensive." (statprof-stop state) (statprof-display port state #:style display-style)))))) -(begin-deprecated - (define-macro (with-statprof . args) - "Profile the expressions in the body, and return the body's return values. - -Keyword arguments: - -@table @code -@item #:display-style -Set the display style, either @code{'flat} or @code{'tree}. - -@item #:loop -Execute the body @var{loop} number of times, or @code{#f} for no looping - -default: @code{#f} -@item #:hz -Sampling rate - -default: @code{20} -@item #:count-calls? -Whether to instrument each function call (expensive) - -default: @code{#f} -@end table" - (define (kw-arg-ref kw args def) - (cond - ((null? args) (error "Invalid macro body")) - ((keyword? (car args)) - (if (eq? (car args) kw) - (cadr args) - (kw-arg-ref kw (cddr args) def))) - ((eq? kw #f def) ;; asking for the body - args) - (else def))) ;; kw not found - (issue-deprecation-warning - "`with-statprof' is deprecated. Use `statprof' instead.") - `((@ (statprof) statprof) - (lambda () ,@(kw-arg-ref #f args #f)) - #:display-style ,(kw-arg-ref #:display-style args ''flat) - #:loop ,(kw-arg-ref #:loop args 1) - #:hz ,(kw-arg-ref #:hz args 100) - #:count-calls? ,(kw-arg-ref #:count-calls? args #f))) - (export with-statprof)) - (define* (gcprof thunk #:key (loop 1) full-stacks? (port (current-output-port))) "Do an allocation profile of the execution of @var{thunk}. diff --git a/module/texinfo/reflection.scm b/module/texinfo/reflection.scm index d85f61239..50cb2ab05 100644 --- a/module/texinfo/reflection.scm +++ b/module/texinfo/reflection.scm @@ -288,16 +288,11 @@ (else (lp (cdr forms)))))) (define* (module-stexi-documentation sym-name - #:optional %docs-resolver #:key (docs-resolver - (or %docs-resolver - (lambda (name def) def)))) + (lambda (name def) def))) "Return documentation for the module named @var{sym-name}. The documentation will be formatted as @code{stexi} (@pxref{texinfo,texinfo})." - (if %docs-resolver - (issue-deprecation-warning - "module-stexi-documentation: use #:docs-resolver instead of a positional argument.")) (let* ((commentary (and=> (module-commentary sym-name) (lambda (x) (string-trim-both x #\newline)))) (stexi (string->stexi commentary)) diff --git a/module/web/client.scm b/module/web/client.scm index 3b7ea5156..c13117dd2 100644 --- a/module/web/client.scm +++ b/module/web/client.scm @@ -48,7 +48,6 @@ #:export (current-http-proxy open-socket-for-uri http-get - http-get* http-head http-post http-put @@ -381,9 +380,7 @@ as is the case by default with a request returned by `build-request'." (body #f) (port (open-socket-for-uri uri)) (version '(1 . 1)) (keep-alive? #f) - ;; #:headers is the new name of #:extra-headers. - (extra-headers #f) (headers (or extra-headers '())) - (decode-body? #t) (streaming? #f)) + (headers '()) (decode-body? #t) (streaming? #f)) "Connect to the server corresponding to URI and ask for the resource, using the ‘GET’ method. If you already have a port open, pass it as PORT. The port will be closed at the end of the @@ -410,30 +407,11 @@ response body has been read. Returns two values: the response read from the server, and the response body as a string, bytevector, #f value, or as a port (if STREAMING? is true)." - (when extra-headers - (issue-deprecation-warning - "The #:extra-headers argument to http-get has been renamed to #:headers. " - "Please update your code.")) (request uri #:method 'GET #:body body #:port port #:version version #:keep-alive? keep-alive? #:headers headers #:decode-body? decode-body? #:streaming? streaming?)) -(define* (http-get* uri #:key - (body #f) - (port (open-socket-for-uri uri)) - (version '(1 . 1)) (keep-alive? #f) - ;; #:headers is the new name of #:extra-headers. - (extra-headers #f) (headers (or extra-headers '())) - (decode-body? #t)) - "Deprecated in favor of (http-get #:streaming? #t)." - (issue-deprecation-warning - "`http-get*' has been deprecated. " - "Instead, use `http-get' with the #:streaming? #t keyword argument.") - (http-get uri #:body body - #:port port #:version version #:keep-alive? keep-alive? - #:headers headers #:decode-body? #t #:streaming? #t)) - (define-syntax-rule (define-http-verb http-verb method doc) (define* (http-verb uri #:key (body #f) diff --git a/module/web/uri.scm b/module/web/uri.scm index 5b01aa41f..4c6fa5051 100644 --- a/module/web/uri.scm +++ b/module/web/uri.scm @@ -75,14 +75,7 @@ (define (uri? obj) (and (uri-reference? obj) - (if (include-deprecated-features) - (begin - (unless (uri-scheme obj) - (issue-deprecation-warning - "Use uri-reference? instead of uri?; in the future, uri? -will require that the object not be a relative-ref.")) - #t) - (uri-scheme obj)) + (uri-scheme obj) #t)) ;;; RFC 3986, #4.2. |