How should context-escaping closures proceed?

D. Clarke, Pascal Costanza, É. Tanter
{"title":"How should context-escaping closures proceed?","authors":"D. Clarke, Pascal Costanza, É. Tanter","doi":"10.1145/1562112.1562113","DOIUrl":null,"url":null,"abstract":"Context-oriented programming treats execution context explicitly and provides means for context-dependent adaptation at runtime. This is achieved, for example, using dynamic layer activation and contextual dispatch, where the context consists of a layer environment of a stack of active layers. Layers can adapt existing behaviour using proceed to access earlier activated layers. A problem arises when a call to proceed is made from within a closure that escapes the layer environment in which it was defined. It is not clear how to interpret proceed when the closure is subsequently applied in a different environment, because the layers it implicitly refers to (such as the original layer and/or the remaining layers) may no longer be active. In this paper, we describe this problem in detail and present some approaches for dealing with it, though ultimately we leave the question open.","PeriodicalId":383693,"journal":{"name":"Proceedings of the 1st ACM International Workshop on Context-Oriented Programming","volume":"7 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2009-07-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"15","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 1st ACM International Workshop on Context-Oriented Programming","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/1562112.1562113","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 15

Abstract

Context-oriented programming treats execution context explicitly and provides means for context-dependent adaptation at runtime. This is achieved, for example, using dynamic layer activation and contextual dispatch, where the context consists of a layer environment of a stack of active layers. Layers can adapt existing behaviour using proceed to access earlier activated layers. A problem arises when a call to proceed is made from within a closure that escapes the layer environment in which it was defined. It is not clear how to interpret proceed when the closure is subsequently applied in a different environment, because the layers it implicitly refers to (such as the original layer and/or the remaining layers) may no longer be active. In this paper, we describe this problem in detail and present some approaches for dealing with it, though ultimately we leave the question open.
上下文转义闭包应该如何进行?
面向上下文的编程显式地处理执行上下文,并提供在运行时进行依赖于上下文的调整的方法。例如,这可以通过使用动态层激活和上下文分派来实现,其中上下文由活动层堆栈的层环境组成。层可以使用proceed访问较早激活的层来适应现有的行为。当对proceed的调用在闭包内进行时,会出现一个问题,该闭包逃避了定义它的层环境。当闭包随后在不同的环境中应用时,不清楚如何解释proceed,因为它隐式引用的层(例如原始层和/或剩余层)可能不再是活动的。在本文中,我们详细描述了这个问题,并提出了一些处理它的方法,尽管最终我们留下了这个问题。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信