CONTEXTS AS FIRST-CLASS OBJECTS: AN IMPLEMENTATION BASED ON THE SICSTUS PROLOG SYSTEM
Enrico Denti, Antônio José Natali, Andrea Omicini · 1999
This work provides a new view of contexts by defining them as primitives data types whose instances can be interpreted in two ways: as structured binding environments and as first-class objects. To achieve such a goal, an implementation is presented in which contexts are completely configured data structures, created by using the SICStus Prolog system support for modular programming. The main advantage of the implementation is to exploit the efficient indirect addressing scheme of SICStus Prolog in order to implement all the contextual binding mechanisms (late binding included) in a uniform way. 1. Introduction Among the open problems of the logic programming field, one of the most critical concerns the extension of the logic paradigm with concepts and mechanisms to support the design, development and maintenance of large software systems. All industrial Prolog systems (e.g. Quintus, SICStus, etc.) provide predicates to partition the single Prolog data-base into a collection o...