ECOOP 2015
Sun 5 - Fri 10 July 2015 Prague, Czech Republic
Sun 5 Jul 2015 16:00 - 16:30 at FIT-107 - Session 3

Layer-introduced base methods, which are the methods with new signatures in a layer and are added to a class, give layers more freedom to organize definitions of context-dependent behavior. However, we need to be careful so as not to call a layer-introduced base method while the layers that provide the method are inactive. Type-based solutions would help to avoid such a problematic situation, but existing ones are limited to context-oriented programming (COP) languages that have dynamically-scoped (i.e., the “with“ based) layer activation. We propose a COP framework in Haskell that supports both imperative and dynamically-scoped layer activation mechanisms, as well as layer-introduced base functions. By representing a context as a stack of active layers in a type of a function in Haskell, type safety—including the guarantee of activation of a layer that provides a layer-introduced function—is checked by the Haskell’s type system. This paper shows how our framework encodes COP features in Haskell using a simple example.

Sun 5 Jul

COP-2015-papers
15:30 - 17:00: COP - Session 3 at FIT-107
COP-2015-papers143610300000015:30 - 16:00
Talk
COP-2015-papers143610480000016:00 - 16:30
Talk
COP-2015-papers143610660000016:30 - 17:00
Other