按年被提到
20232023 · 1 次2026
编程语言与编译器›Rust 与内存安全·arXiv:2310.18166 · cs.PL

Functional Ownership through Fractional Uniqueness

Danielle Marshall, Dominic Orchard · 2023
开始阅读 ↗PDFalphaXiv 讨论
被提及 · 2 人首次 2023-11-07 · 最近 2024-02-29
2不同的人
2活跃月份
2讨论串
7被引(OpenAlex)
arXiv 摘要(候选层不写导读)

Ownership and borrowing systems, designed to enforce safe memory management without the need for garbage collection, have been brought to the fore by the Rust programming language. Rust also aims to bring some guarantees offered by functional programming into the realm of performant systems code, but the type system is largely separate from the ownership model, with type and borrow checking happening in separate compilation phases. Recent models such as RustBelt and Oxide aim to formalise Rust in depth, but there is less focus on integrating the basic ideas into more traditional type systems. An approach designed to expose an essential core for ownership and borrowing would open the door for functional languages to borrow concepts found in Rust and other ownership frameworks, so that more programmers can enjoy their benefits. One strategy for managing memory in a functional setting is through uniqueness types, but these offer a coarse-grained view: either a value has exactly one reference, and can be mutated safely, or it cannot, since other references may exist. Recent work demonstrates that linear and uniqueness types can be combined in a single system to offer restrictions on program behaviour and guarantees about memory usage. We develop this connection further, showing that just as graded type systems like those of Granule and Idris generalise linearity, Rust's ownership model arises as a graded generalisation of uniqueness. We combine fractional permissions with grading to give the first account of ownership and borrowing that smoothly integrates into a standard type system alongside linearity and graded types, and extend Granule accordingly with these ideas.

候选层:至少 2 个不同的人、在 2 个不同月份提到过,还没到主书架的 3 人 3 个月。没有做立场标注,所以只写“被提及”。

HN 书评

没有评论直接链到它;下面是它被提交的讨论串里回复最多的评论(不计入统计)
讨论串评论waynecochran · 2024-02

“the Rust compiler is able to infer that allowing two mutable borrows is safe as long as one of them is never used This (i.e. proving a variable is never used) is impossible in general since it is equivalent to the halting problem. There are many cases where it can be solved, so the compiler lets the programmer get away with this in the cases where one of …”

Functional ownership through fractional uniqueness原评论 ↗
讨论串评论digdugdirk · 2024-03

“What're some good resources to build up the knowledge base needed to understand this article? I've always been fascinated by the building blocks of computation, there just seems to be a massive investment required to get that understanding.”

Functional ownership through fractional uniqueness原评论 ↗
讨论串评论throwaway17_17 · 2024-03

“The work done in the Gradle project by Orchard, et al has been consistently good. I think a really solid progression from this paper is to take the same approach and combine it with the type system feature in ‘A Flexible Type System for Fearless Concurrency’ (Milano,etal 2022) [1]. The thrust of said paper is to utilize a coarser grain for ‘objects’ than …”

Functional ownership through fractional uniqueness原评论 ↗
被提交为 story · 2 次