1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00

Remove unused variables in ice-9/goops/srfi/scripts.

* module/ice-9/boot-9.scm (scm-style-repl)[-abort]: Remove.

* module/oop/goops.scm (class)[slot-defs]: Remove.
  (compute-slot-accessors)[name]: Remove.
  (compute-get-n-set)[env]: Remove.

* module/oop/goops/active-slot.scm (compute-get-n-set)[env, name]:
  Remove.

* module/oop/goops/dispatch.scm (cache-try-hash!)[max-misses]: Remove.

* module/oop/goops/save.scm (make-mapper)[dims]: Remove.

* module/scripts/autofrisk.scm (>>checks)[prog]: Remove.

* module/srfi/srfi-19.scm (priv:read-directives)[ireaderf, eireader4]:
  Remove.
This commit is contained in:
Ludovic Courtès 2009-09-21 00:10:28 +02:00
parent f65e2b1ec5
commit a2ca725212
7 changed files with 12 additions and 30 deletions

View file

@ -2811,15 +2811,7 @@ module '(ice-9 q) '(make-q q-length))}."
(display ";;; QUIT executed, repl exitting")
(newline)
(repl-report)))
args))
(-abort (lambda ()
(if scm-repl-verbose
(begin
(display ";;; ABORT executed.")
(newline)
(repl-report)))
(repl -read -eval -print))))
args)))
(let ((status (error-catching-repl -read
-eval

View file

@ -1,6 +1,6 @@
;;; installed-scm-file
;;;; Copyright (C) 1998,1999,2000,2001,2002, 2003, 2006 Free Software Foundation, Inc.
;;;; Copyright (C) 1998,1999,2000,2001,2002, 2003, 2006, 2009 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
@ -226,8 +226,7 @@
slots))
(if (not (list? supers))
(goops-error "malformed superclass list: ~S" supers))
(let ((slot-defs (cons #f '()))
(slots (take-while (lambda (x) (not (keyword? x))) slots))
(let ((slots (take-while (lambda (x) (not (keyword? x))) slots))
(options (or (find-tail keyword? slots) '())))
`(make-class
;; evaluate super class variables
@ -1074,8 +1073,7 @@
(define (compute-slot-accessors class slots env)
(for-each
(lambda (s g-n-s)
(let ((name (slot-definition-name s))
(getter-function (slot-definition-getter s))
(let ((getter-function (slot-definition-getter s))
(setter-function (slot-definition-setter s))
(accessor (slot-definition-accessor s)))
(if getter-function
@ -1412,8 +1410,7 @@
((#:virtual) ;; No allocation
;; slot-ref and slot-set! function must be given by the user
(let ((get (get-keyword #:slot-ref (slot-definition-options s) #f))
(set (get-keyword #:slot-set! (slot-definition-options s) #f))
(env (class-environment class)))
(set (get-keyword #:slot-set! (slot-definition-options s) #f)))
(if (not (and get set))
(goops-error "You must supply a #:slot-ref and a #:slot-set! in ~S"
s))

View file

@ -1,6 +1,6 @@
;;; installed-scm-file
;;;; Copyright (C) 1999, 2001, 2006 Free Software Foundation, Inc.
;;;; Copyright (C) 1999, 2001, 2006, 2009 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
@ -34,9 +34,7 @@
(define-method (compute-get-n-set (class <active-class>) slot)
(if (eq? (slot-definition-allocation slot) #:active)
(let* ((index (slot-ref class 'nfields))
(name (car slot))
(s (cdr slot))
(env (class-environment class))
(before-ref (get-keyword #:before-slot-ref s #f))
(after-ref (get-keyword #:after-slot-ref s #f))
(before-set! (get-keyword #:before-slot-set! s #f))

View file

@ -1,4 +1,4 @@
;;;; Copyright (C) 1999, 2000, 2001, 2003, 2006 Free Software Foundation, Inc.
;;;; Copyright (C) 1999, 2000, 2001, 2003, 2006, 2009 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
@ -186,8 +186,7 @@
(set! sum (+ sum (struct-ref (car classes) hashset-index))))))
(define (cache-try-hash! min-misses hashset cache entries)
(let ((max-misses 0)
(mask (- (vector-length cache) 1)))
(let ((mask (- (vector-length cache) 1)))
(let outer ((in entries) (max-misses 0))
(if (null? in)
max-misses

View file

@ -1,6 +1,6 @@
;;; installed-scm-file
;;;; Copyright (C) 2000,2001,2002, 2006 Free Software Foundation, Inc.
;;;; Copyright (C) 2000,2001,2002, 2006, 2009 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
@ -183,8 +183,7 @@
(enumerate-component! (shared-array-root o) env))
(define (make-mapper array)
(let* ((dims (array-dimensions array))
(n (array-rank array))
(let* ((n (array-rank array))
(indices (reverse (if (<= n 11)
(list-tail '(t s r q p n m l k j i) (- 11 n))
(let loop ((n n)

View file

@ -1,6 +1,6 @@
;;; autofrisk --- Generate module checks for use with auto* tools
;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
;; Copyright (C) 2002, 2006, 2009 Free Software Foundation, Inc.
;;
;; This program is free software; you can redistribute it and/or
;; modify it under the terms of the GNU Lesser General Public License
@ -157,7 +157,6 @@
(files (apply append (map unglob (cfg 'files-glob))))
(ncx (cfg 'non-critical-external))
(nci (cfg 'non-critical-internal))
(prog (cfg 'non-critical))
(report ((make-frisker) files))
(external (report 'external)))
(let ((pww-varname (cfg 'pww-varname)))

View file

@ -1,6 +1,6 @@
;;; srfi-19.scm --- Time/Date Library
;; Copyright (C) 2001, 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
;; Copyright (C) 2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009 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
@ -1345,9 +1345,7 @@
(define priv:read-directives
(let ((ireader4 (priv:make-integer-reader 4))
(ireader2 (priv:make-integer-reader 2))
(ireaderf (priv:make-integer-reader #f))
(eireader2 (priv:make-integer-exact-reader 2))
(eireader4 (priv:make-integer-exact-reader 4))
(locale-reader-abbr-weekday (priv:make-locale-reader
priv:locale-abbr-weekday->index))
(locale-reader-long-weekday (priv:make-locale-reader