Transactional contexts: harnessing the power of context-oriented reflection

  • Authors:
  • Sebastián González;Marcus Denker;Kim Mens

  • Affiliations:
  • Université catholique de Louvain;University of Chile;Université catholique de Louvain

  • Venue:
  • International Workshop on Context-Oriented Programming
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

The emerging field of context-oriented programming gives a predominant role to the execution context of applications, and advocates the use of dedicated mechanisms to allow the elegant expression of behavioural adaptations to such context. With suitable reflective facilities, language semantics can be adapted to context by reusing the same context-oriented mechanisms that allow base-level adaptability. This kind of meta-level adaptability, in which the computation model itself becomes adaptable to context, gives rise to context-oriented computational reflection. To explore this idea, we set out to implement a simple software transactional memory system that exploits meta-level adaptability by regarding transactions as contexts, and adapting fundamental system behaviour to such transactional contexts. The implementation is succinct and non-intrusive, giving us an indication of the power lying at the crossroads of context-oriented programming and computational reflection.