Syntactic abstraction in Scheme

RK Dybvig, R Hieb, C Bruggeman - Lisp and symbolic computation, 1993 - Springer
RK Dybvig, R Hieb, C Bruggeman
Lisp and symbolic computation, 1993Springer
Naive program transformations can have surprising effects due to the interaction between
introduced identifier references and previously existing identifier bindings, or between
introduced bindings and previously existing references. These interactions can result in
inadvertent binding, or capturing, of identifiers. A further complication is that transformed
programs may have little resemblance to original programs, making correlation of source
and object code difficult. This article describes an efficient macro system that prevents …
Abstract
Naive program transformations can have surprising effects due to the interaction between introduced identifier references and previously existing identifier bindings, or between introduced bindings and previously existing references. These interactions can result in inadvertent binding, or capturing, of identifiers. A further complication is that transformed programs may have little resemblance to original programs, making correlation of source and object code difficult. This article describes an efficient macro system that prevents inadvertent capturing while maintaining the correlation between source and object code. The macro system allows the programmer to define program transformations using an unrestricted, general-purpose language. Previous approaches to the capturing problem have been inadequate, overly restrictive, or inefficient, and the problem of source-object correlation has been largely unaddressed. The macro system is based on a new algorithm for implementing syntactic transformations and a new representation for syntactic expressions.
Springer