Hygienic Literate Programming: Lessons From ChezWEB

Date Added: Oct 2011
Format: PDF

Literate programming systems are a class of domain specific languages designed to encourage writing programs specifically to be read as essays or books by humans instead of by machines. Systems like CWEB, WEB, and ChezWEB allow the user to associate arbitrary code bodies with a concise but natural language description. That description may then be referred to in other sections of the program source, and the code body associated with the description is substituted for the reference in the program source. Using Scheme macros, the authors describe how this substitution is performed unhygienically.