Hi Vasily, For completeness sake, note that you can use let-syntax and make the macro expander do the work of substitute-syntax.
(require (for-syntax syntax/parse)) (define-syntax (recursion stx) (syntax-parse stx [(_recursion name (arg ...) expr) #'( (λ (x) (x x)) (λ (name) (λ (arg ...) (let-syntax ([name (λ (stx) (syntax-parse stx [(_name . more) #'((name name) . more)] [other #'other]))]) expr))))])) 2016-09-11 17:33 GMT+02:00 Vasily Rybakov <madbada...@gmail.com>: > Also thanks to Jens and Sam -- your examples is valuable, I learned from > them (for example, how I can use (let) to bind variable that was defined > before -- so it keeps previous binding in the definitions part of (let) but > uses new binding in the body part of (let)). > > -- > You received this message because you are subscribed to the Google Groups > "Racket Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to racket-users+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -- -- Jens Axel Søgaard -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to racket-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.