/[gcl]/gcl/ansi-tests/random-type-prop.lsp
ViewVC logotype

Diff of /gcl/ansi-tests/random-type-prop.lsp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.12 by pfdietz, Sat Apr 23 14:17:20 2005 UTC revision 1.13 by pfdietz, Mon Jul 4 13:18:15 2005 UTC
# Line 366  Line 366 
366       (1 `(,root ,etype ,(loop for i below rank collect (make-random-array-dimension-spec val i))))       (1 `(,root ,etype ,(loop for i below rank collect (make-random-array-dimension-spec val i))))
367       (1 `(,root ,etype ,(loop for i below rank collect (array-dimension val i))))       (1 `(,root ,etype ,(loop for i below rank collect (array-dimension val i))))
368       #-ecl (1 `(,root ,etype ,rank))       #-ecl (1 `(,root ,etype ,rank))
369         (4 (call-next-method))
370       )))       )))
371    
372  (defmethod make-random-type-containing ((val string))  (defmethod make-random-type-containing ((val string))
373    (rcase    (rcase
374     (1 (let ((root (if (and (coin)     (1 (let ((root (cond
375                             (typep val 'simple-string))                     ((and (coin)
376                        'simple-string                           (typep val 'base-string))
377                      'string)))                      (cond
378                         ((and (coin) (typep val 'simple-base-string))
379                          'simple-base-string)
380                         (t 'base-string)))
381                       ((and (coin)
382                             (typep val 'simple-string))
383                        'simple-string)
384                       (t 'string))))
385          (rcase (1 root)          (rcase (1 root)
386                 (1 `(,root))                 (1 `(,root))
387                 (3 `(,root ,(make-random-array-dimension-spec val 0))))))                 (3 `(,root ,(make-random-array-dimension-spec val 0))))))
# Line 426  Line 434 
434          'function))          'function))
435     (1 t)))     (1 t)))
436    
437    (defmethod make-random-type-containing ((val sequence))
438      (rcase
439       (1 'sequence)
440       (2 (call-next-method))))
441    
442  ;;; Macro for defining random type prop tests  ;;; Macro for defining random type prop tests
443    
444  (defmacro def-type-prop-test (name &body args)  (defmacro def-type-prop-test (name &body args)

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.13

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26