We describe a type system with mixed linear and non-linear recursive types called LNL-FPC (the linear/non-linear fixpoint calculus). The type system supports linear typing, which enhances the safety properties of programs, but also supports non-linear typing as well, which makes the type system more convenient for programming. Just as in FPC, we show that LNL-FPC supports type-level recursion, which in turn induces term-level recursion. We also provide sound and computationally adequate categorical models for LNL-FPC that describe the categorical structure of the substructural operations of Intuitionistic Linear Logic at all non-linear types, including the recursive ones. In order to do so, we describe a new technique for solving recursive domain equations within cartesian categories by constructing the solutions over pre-embeddings. The type system also enjoys implicit weakening and contraction rules that we are able to model by identifying the canonical comonoid structure of all non-linear types. We also show that the requirements of our abstract model are reasonable by constructing a large class of concrete models that have found applications not only in classical functional programming, but also in emerging programming paradigms that incorporate linear types, such as quantum programming and circuit description programming languages.
翻译:我们描述的是一种类型系统,其类型有线性和非线性递归类型,称为LNL-FPC(线性/非线性固定点微积分)。类型系统支持线性打字,这可以增强程序的安全性,同时也支持非线性打字,使类型系统更便于编程。正如在FPC中一样,我们显示LNL-FPC支持类型级递转,这反过来又会引发定期循环。我们还为LNL-FPC提供了健全的和计算上充分的绝对模型,用以描述所有非线性线性线性线性线性线性线性线性线性亚结构操作的绝对结构结构,包括循环性线性线性线性线性线性线性计算。为了做到这一点,我们描述了一种解决卡尔提亚类内递归性域等方程式的新技术,通过在编程前的解决方案中构建解决方案,解决型号的递归回式重域方程式。类型系统也享有隐含的削弱和收缩规则,我们通过确定所有非线性型类的共线性共质类结构结构来进行模拟的模型进行模拟。我们还显示,我们在抽象性线性线性线性线性线性线性线性线性线性线性线性线性线性模型的要求在构建模型中,在构建模型中,在构建的模型中,在构建中,在构建中也并不合理。我们所找到的模型。我们所学型号型号型号型的模型,在构建的模型,在构建的模型中,在构建的模型,在构建的模型中,在构建的模型中,在构建的模型中,在构建的模型中,在构建的模型中,在构建的模型中,在构建的模型中,在构建了一种新型型号型号型号型号型号型号型号型号型号型号型号型号图制制制制程中,而不能。我们。