Generic packages in C

  • Authors:
  • Dick Grune

  • Affiliations:
  • Vrije Universiteit, de Boelelaan 1081, 1081 HV, Amsterdam

  • Venue:
  • ACM SIGPLAN Notices
  • Year:
  • 1986

Quantified Score

Hi-index 0.00

Visualization

Abstract

The structuring achieved by generic packages in Ada can be cheaply emulated in C by judicious use of the preprocessor. Two files are required for the generic package: the specification and the body. Two more files are used in the instantiation: one holding the instantiation parameters and one with auxiliary code. Instantiation results in normal C header and object files (*.h and *.o). Dependency control can be delegated to the make progam.