;; Compatibility library for mzscheme 3xx and 4.x. ;; The syntax-local-value of a structure type changed in 3.99. (module struct-info-compat mzscheme (require (planet "version-case.ss" ("dyoo" "version-case.plt" 1 4))) (version-case [(version< (version) "3.99") (define (get-struct-predicate type-stx) (list-ref (syntax-local-value type-stx) 2))] [else (require scheme/struct-info) (define (get-struct-predicate type-stx) (list-ref (extract-struct-info (syntax-local-value type-stx)) 2))]) (provide get-struct-predicate))