当前位置: X-MOL 学术arXiv.cs.PL › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Adjoint Reactive GUI
arXiv - CS - Programming Languages Pub Date : 2020-10-23 , DOI: arxiv-2010.12338
Christian Uldal Graulund, Dmitrij Szamozvancev, Neel Krishnaswami

Most interaction with a computer is done via a graphical user interface. Traditionally, these are implemented in an imperative fashion using shared mutable state and callbacks. This is efficient, but is also difficult to reason about and error prone. Functional Reactive Programming (FRP) provides an elegant alternative which allows GUIs to be designed in a declarative fashion. However, most FRP languages are synchronous and continually check for new data. This means that an FRP-style GUI will "wake up" on each program cycle. This is problematic for applications like text editors and browsers, where often nothing happens for extended periods of time, and we want the implementation to sleep until new data arrives. In this paper, we present an asynchronous FRP language for designing GUIs called $\lambda_{\mathsf{Widget}}$. Our language provides a novel semantics for widgets, the building block of GUIs, which offers both a natural Curry--Howard logical interpretation and an efficient implementation strategy.

中文翻译:

伴随反应 GUI

大多数与计算机的交互是通过图形用户界面完成的。传统上,这些是使用共享的可变状态和回调以命令式方式实现的。这是有效的,但也难以推理并且容易出错。函数式反应式编程 (FRP) 提供了一种优雅的替代方案,它允许以声明方式设计 GUI。但是,大多数 FRP 语言都是同步的,并且会不断检查新数据。这意味着 FRP 样式的 GUI 将在每个程序周期中“唤醒”。这对于像文本编辑器和浏览器这样的应用程序来说是有问题的,在这些应用程序中,通常很长时间没有任何事情发生,我们希望实现在新数据到达之前休眠。在本文中,我们提出了一种用于设计 GUI 的异步 FRP 语言 $\lambda_{\mathsf{Widget}}$。
更新日期:2020-10-27
down
wechat
bug