English

Local Modules in Imperative Languages

Programming Languages 2017-10-20 v4

Abstract

We propose a notion of local modules for imperative langauges. To be specific, we introduce a new implication statement of the form DGD \supset G where DD is a module (i.e., a set of procedure declarations) and GG is a statement. This statement tells the machine to add DD to the program in the course of executing GG. Thus, DD acts as a local module and will be discarded after executing GG. It therefore provides efficient module management. We illustrate our idea via C^{mod}, an extension of the core C with the new statement. In addition, we describe a new constructive module language to improve code reuse. Finally, we describe a scheme which considerably improves the heap management in traditional languages.

Keywords

Cite

@article{arxiv.1701.05034,
  title  = {Local Modules in Imperative Languages},
  author = {Keehang Kwon and Daeseong Kang},
  journal= {arXiv preprint arXiv:1701.05034},
  year   = {2017}
}

Comments

5 pages. A high-level statement for allocating and deallocating heap objects is described and a constructive module language is also described

R2 v1 2026-06-22T17:53:06.427Z