Note on Conditional Compilation in Standard ML

  • Authors:
  • Nicholas Haines;Edoardo Biagioni;Robert Harper;Brian G. Milnes

  • Affiliations:
  • -;-;-;-

  • Venue:
  • Note on Conditional Compilation in Standard ML
  • Year:
  • 1993

Quantified Score

Hi-index 0.00

Visualization

Abstract

Keywords: Standard ML, modules, functors, conditional compilation, code style, optimzing compilers 7 pages [FTP: CMU-CS-93-172.ps] In the Fox project we make frequent use of conditional code within Standard ML functors: code which depends on the functor arguments. The canonical example is instrumentation code for testing or debugging, only present when flags in the functor arguments are set. We would like the object code of instantiations of these functors to be as efficient as possible, i.e., to omit the code when the argument flags are not set. This note considers compilation techniques to achieve this goal, and code styles which do well in the absence of such techniques.