当前位置: 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.)
Hailstorm : A Statically-Typed, Purely Functional Language for IoT Applications
arXiv - CS - Programming Languages Pub Date : 2021-05-27 , DOI: arxiv-2105.13468
Abhiroop Sarkar, Mary Sheeran

With the growing ubiquity of Internet of Things(IoT), more complex logic is being programmed on resource-constrained IoT devices, almost exclusively using the C programming language. While C provides low-level control over memory, it lacks a number of high-level programming abstractions such as higher-order functions, polymorphism, strong static typing, memory safety, and automatic memory management. We present Hailstorm, a statically-typed, purely functional programming language that attempts to address the above problem. It is a high-level programming language with a strict typing discipline. It supports features like higher-order functions, tail-recursion, and automatic memory management, to program IoT devices in a declarative manner. Applications running on these devices tend to be heavily dominated by I/O. Hailstorm tracks side effects likeI/O in its type system using resource types. This choice allowed us to explore the design of a purely functional standalone language, in an area where it is more common to embed a functional core in an imperative shell. The language borrows the combinators of arrowized FRP, but has discrete-time semantics. The design of the full set of combinators is work in progress, driven by examples. So far, we have evaluated Hailstorm by writing standard examples from the literature (earthquake detection, a railway crossing system and various other clocked systems), and also running examples on the GRiSP embedded systems board, through generation of Erlang.

中文翻译:

Hailstorm:一种用于物联网应用的静态类型、纯函数式语言

随着物联网 (IoT) 的日益普及,更多复杂的逻辑正在资源受限的物联网设备上进行编程,几乎完全使用 C 编程语言。尽管 C 提供了对内存的低级控制,但它缺乏许多高级编程抽象,例如高阶函数、多态性、强静态类型、内存安全和自动内存管理。我们提出了 Hailstorm,一种静态类型的纯函数式编程语言,试图解决上述问题。它是一种具有严格类型规则的高级编程语言。它支持高阶函数、尾递归和自动内存管理等功能,以声明方式对物联网设备进行编程。在这些设备上运行的应用程序往往主要由 I/O 控制。Hailstorm 使用资源类型跟踪其类型系统中的 I/O 等副作用。这种选择使我们能够探索纯函数式独立语言的设计,在一个更常见的领域中,将函数式核心嵌入到命令式 shell 中。该语言借用了箭头化 FRP 的组合子,但具有离散时间语义。在示例的推动下,全套组合器的设计正在进行中。到目前为止,我们通过编写文献中的标准示例(地震检测、铁路道口系统和各种其他时钟系统)以及在 GRiSP 嵌入式系统板上运行示例,通过生成 Erlang 来评估 Hailstorm。在一个更常见的领域,在命令式 shell 中嵌入一个功能核心。该语言借用了箭头化 FRP 的组合子,但具有离散时间语义。在示例的推动下,全套组合器的设计正在进行中。到目前为止,我们通过编写文献中的标准示例(地震检测、铁路道口系统和各种其他时钟系统)以及在 GRiSP 嵌入式系统板上运行示例,通过生成 Erlang 来评估 Hailstorm。在一个更常见的领域,在命令式 shell 中嵌入一个功能核心。该语言借用了箭头化 FRP 的组合子,但具有离散时间语义。在示例的推动下,全套组合器的设计正在进行中。到目前为止,我们通过编写文献中的标准示例(地震检测、铁路道口系统和各种其他时钟系统)以及在 GRiSP 嵌入式系统板上运行示例,通过生成 Erlang 来评估 Hailstorm。
更新日期:2021-05-31
down
wechat
bug