#lang scheme/base (require (for-template scheme/base)) (define (cond* stx) (syntax-case stx (else) ((~) #`(void)) ((~ (else exp exp2 ...)) #`(begin (void) exp exp2 ...)) ((~ (test exp exp2 ...) rest ...) #`(if test (begin exp exp2 ...) #,(cond* #`(cond* #,@#'(rest ...))))) )) (provide cond* )