Semantically-Sensitive Macroprocessing

Abstract

Conventional procedure and type definition mechanisms are not sufficiently powerful to express many programming aberrations that can be captured by syntactic transformations. Unfortunately, conventional macroprocessing is oblivious to the semantics of the base language, resulting in scoping anomalies, poor handling of static semantic errors, and an inability to perform transformations dependent on semantic attributes of the manipulated program. We introduce a new mechanism, semantic macros, which permit such transformations a significant level of access to the static semantic properties of the program fragments they manipulate. In this way, new static semantic processing, including compilation of embedded languages with a rich static semantics of their own, can be incorporated into user-defined language extensions. A proof-of-concept language, XL, is described which embodies this mechanism.

Open PDF

Document Details

Document Type
Technical Report
Publication Date
Dec 15, 1989
Accession Number
ADA632162

Entities

People

  • William Maddox

Organizations

  • University of California, Berkeley

Tags

Communities of Interest

  • Energy and Power Technologies

DTIC Thesaurus Topics

  • Application Software
  • Compilers
  • Computations
  • Computer Programming
  • Computer Programs
  • Computer Science
  • Computers
  • Debugging
  • Grammars
  • Language
  • Linguistics
  • Lisp Programming Language
  • Operating Systems
  • Programming Languages
  • Semantic Models
  • Semantics
  • Side Effects

Fields of Study

  • Computer science

Readers

  • Artificial Intelligence
  • Geodesy
  • Parallel and Distributed Computing.