Le dimanche 4 décembre 2016 02:56:23 UTC+1, mflatt a écrit : > > (define (empty-scopes-everywhere? e) > (cond > [(syntax? e) > (and (bound-identifier=? (datum->syntax #f 'x) > (datum->syntax e 'x)) > (empty-scopes-everywhere? (syntax-e e)))] > [(pair? e) (and (empty-scopes-everywhere? (car e)) > (empty-scopes-everywhere? (cdr e)))] > [(vector? e) (for/and ([elem (in-vector e)]) > (empty-scopes-everywhere? elem))] > [(box? e) (empty-scopes-everywhere? (unbox e))] > [(prefab-struct-key e) > (empty-scopes-everywhere? (struct->vector e))] > [else #t])) >
This probably should also include a case for hash: [(hash? e) (empty-scopes-everywhere (hash->list e))] -- You received this message because you are subscribed to the Google Groups "Racket Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/racket-dev/0f1bffc3-3008-4cc0-a2e9-e8154f4b35c9%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
