Is it posible to do this to avoid code duplication, or renaming shenanigans. added by Jubjub on Tue May 6 21:14:11 2014
(define (list-ref-default l n default) (if (>= n (length l)) default (list-ref l n))) (define-for-syntax list-ref-default list-ref-default) ; doesn't work, but it would be nice if it did (define-for-syntax list-ref-default (lambda (l n default) (if (>= n (length l)) default (list-ref l n))))