Published In

24th European Symposium on Programming, ESOP 2015

Document Type

Post-Print

Publication Date

2015

Subjects

Computer science, Artificial intelligence, Information storage and retrieval systems, Data mining, Database management, Computer algorithms

Abstract

We describe a language-independent theory for name binding and resolution, suitable for programming languages with complex scoping rules including both lexical scoping and modules. We formulate name resolution as a two-stage problem. First a language-independent scope graph is constructed using language-specific rules from an abstract syntax tree. Then references in the scope graph are resolved to corresponding declarations using a language-independent resolution process. We introduce a resolution calculus as a concise, declarative, and language- independent specification of name resolution. We develop a resolution algorithm that is sound and complete with respect to the calculus. Based on the resolution calculus we develop language-independent definitions of equivalence and rename refactoring. We illustrate the approach using a small example language with modules. In addition, we show how our approach provides a model for a range of name binding patterns in existing languages.

Description

This is the postprint version of a paper presented at the 24th European Symposium on Programming, ESOP 2015, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2015, London, UK, April 11-18, 2015, Proceedings

Find an extended technical report here: http://swerl.tudelft.nl/twiki/pub/Main/TechnicalReports/TUD-SERG-2015-001.pdf

Find the publisher version here:
http://link.springer.com/chapter/10.1007/978-3-662-46669-8_9

DOI

10.1007/978-3-662-46669-8_9

Persistent Identifier

http://archives.pdx.edu/ds/psu/16806

Share

COinS