Macros in higher-level languages

Henry J. Bowlden · 1971

The concept of macros, as a tool to extend the expressive capability of a symbolic language by techniques of string substitution, has existed in the lexicon of programming languages for many years. It has been used most effectively in connection with assemblers; in some cases capabilities not too far short of the range commonly attributed to “higher-level languages” have been provided by this means. Attempts to extend higher-level languages by similar tools have, however, not been quite as well received. In this presentation we consider the lessons which have been learned in the course of a six-year experiment with a macro preprocessor for a dialect of ALGOL 60. The factors which we find of interest are those of user convenience, flexibility, efficiency, and syntactic integrity. We attempt to relate these, in the framework of our own experience, to the independent variables of base language power, user orientation, and design goals. It is not our purpose to arrive at any sweeping generalizations; rather, we will content ourselves with drawing tentative conclusions with respect to fruitful avenues of development from a rather limited base with the help of some specific examples.

Read the paper · More papers on PaperTik