chickadee » chicken » syntax » define-for-syntax

(define-for-syntax (NAME VAR ...) EXP1 ...)syntax
(define-for-syntax (NAME VAR1 ... VARn . VARn+1) EXP1 ...)syntax
(define-for-syntax NAME [VALUE])syntax

Defines the toplevel variable NAME at macro-expansion time. This can be helpful when you want to define support procedures for use in macro-transformers, for example.

Essentially, this is a shorthand for (begin-for-syntax (define ...)).

Note that define-for-syntax definitions within a module are implicitly added to that module's import library. Refer to the documentation on import libraries for more information.