;;;; whether to permit this exception to apply to your modifications.
;;;; If you do not wish that, delete this exception notice.
-(use-modules (ice-9 doc))
+(use-modules (ice-9 documentation))
;;;
;; Is documentation available?
- (pass-if "documented?"
- (let ((documented #f))
- (with-output-to-string
- (lambda ()
- (set! documented (documentation 'append!))))
- documented))
+ (pass-if "documented?" (object-documentation append!))
;; Is the handling of empty lists as arguments correct?
;;;; whether to permit this exception to apply to your modifications.
;;;; If you do not wish that, delete this exception notice.
-(use-modules (ice-9 doc))
+(use-modules (ice-9 documentation))
;;;
;;;
-(define (documented? identifier)
- (let ((documented #f))
- (with-output-to-string
- (lambda ()
- (set! documented (documentation identifier))))
- documented))
+(define (documented? object)
+ (object-documentation object))
(define (make-test-name . args)
;; Is documentation available?
(pass-if "documented?"
- (documented? 'exact?))
+ (documented? exact?))
;; Special case: 0
;; Is documentation available?
(expect-fail "documented?"
- (documented? 'quotient))
+ (documented? quotient))
;; Special case: 0 / n
;; Is documentation available?
(expect-fail "documented?"
- (documented? 'remainder))
+ (documented? remainder))
;; Special case: 0 / n
;; Is documentation available?
(expect-fail "documented?"
- (documented? 'modulo))
+ (documented? modulo))
;; Special case: 0 % n
;; Is documentation available?
(expect-fail "documented?"
- (documented? 'gcd))
+ (documented? gcd))
;; Special case: gcd 0 n
;; Is documentation available?
(expect-fail "documented?"
- (documented? '<))
+ (documented? <))
;; Special case: 0 < n