Journal of Functional Programming最新文献

筛选
英文 中文
A correct-by-construction conversion from lambda calculus to combinatory logic 从λ演算到组合逻辑的按结构正确的转换
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2023-11-22 DOI: 10.1017/s0956796823000084
WOUTER SWIERSTRA
{"title":"A correct-by-construction conversion from lambda calculus to combinatory logic","authors":"WOUTER SWIERSTRA","doi":"10.1017/s0956796823000084","DOIUrl":"https://doi.org/10.1017/s0956796823000084","url":null,"abstract":"This pearl defines a translation from well-typed lambda terms to combinatory logic, where both the preservation of types and the correctness of the translation are enforced statically.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"5 1","pages":""},"PeriodicalIF":1.1,"publicationDate":"2023-11-22","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"138531891","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
PhD Abstracts 摘要博士
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2023-07-24 DOI: 10.1017/S0956796823000035
G. Hutton
{"title":"PhD Abstracts","authors":"G. Hutton","doi":"10.1017/S0956796823000035","DOIUrl":"https://doi.org/10.1017/S0956796823000035","url":null,"abstract":"Dependently typed programming languages provide a way to write programs, specifica-tions","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":" ","pages":""},"PeriodicalIF":1.1,"publicationDate":"2023-07-24","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"45862215","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Read/write factorizable programs 读/写可分解程序
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2023-06-08 DOI: 10.1017/S0956796823000023
Siddharth Bhaskar, J. Simonsen
{"title":"Read/write factorizable programs","authors":"Siddharth Bhaskar, J. Simonsen","doi":"10.1017/S0956796823000023","DOIUrl":"https://doi.org/10.1017/S0956796823000023","url":null,"abstract":"Abstract In the cons-free programming paradigm, we eschew constructors and program using only destructors. Cons-free programs in a simple first-order language with string data capture exactly P, the class of polynomial-time relations. By varying the underlying language and considering other data types, we can capture several other complexity classes. However, no cons-free programming language captures any functional complexity class for fundamental reasons. In this paper, we cleanly extend the cons-free paradigm to encompass functional complexity classes. Namely, we introduce programs with data that can either only be destructed or only be constructed, which we enforce by a type system on the program variables. We call the resulting programs read/write- (or RW-)factorizable, show that RW-factorizable string programs capture exactly the class FP of polynomial-time functions, and that tail-recursive RW-factorizable programs capture exactly the class FL of logarithmic-space functions. Finally, we state and solve the nontrivial problem of syntactic composition of two RW-factorizable programs.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":" ","pages":""},"PeriodicalIF":1.1,"publicationDate":"2023-06-08","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"43689921","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Fold-unfold lemmas for reasoning about recursive programs using the Coq proof assistant – ERRATUM 使用Coq证明助手ERRATUM对递归程序进行推理的折叠展开引理
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2023-03-06 DOI: 10.1017/s0956796823000011
O. Danvy
{"title":"Fold-unfold lemmas for reasoning about recursive programs using the Coq proof assistant – ERRATUM","authors":"O. Danvy","doi":"10.1017/s0956796823000011","DOIUrl":"https://doi.org/10.1017/s0956796823000011","url":null,"abstract":"","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"33 1","pages":""},"PeriodicalIF":1.1,"publicationDate":"2023-03-06","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"42282522","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Folding left and right matters: Direct style, accumulators, and continuations 左右折叠事项:直接样式、累加器和延续
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2023-02-14 DOI: 10.1017/S0956796822000156
O. Danvy
{"title":"Folding left and right matters: Direct style, accumulators, and continuations","authors":"O. Danvy","doi":"10.1017/S0956796822000156","DOIUrl":"https://doi.org/10.1017/S0956796822000156","url":null,"abstract":"Abstract The equivalence of folding left and right over Peano numbers and lists makes it possible to minimalistically inter-derive (1) structurally recursive functions in direct style, (2) structurally tail-recursive functions that use an accumulator, and (3) structurally tail-recursive functions in delimited continuation-passing style, using Ohori and Sasano’s lightweight fusion by fixed-point promotion. When the fold-left and the fold-right functions account for primitive iteration for Peano numbers, this equivalence is unconditional. When they account for primitive recursion for Peano numbers, this equivalence is modulo left permutativity of their induction-step parameter – a property which is more general than associativity and commutativity. And when they account for primitive iteration or for primitive recursion over lists, this equivalence is modulo left permutativity of their induction-step parameter if these two fold functions have the same type. Since the 1980s, however, the two fold functions for lists do not have the same type: the arguments for their induction-step parameter are swapped, a re-ordering that complicated Bird and Wadler’s duality theorems and whose history is reviewed in an appendix. Without this re-ordering, Bird and Wadler’s second duality theorem more visibly accounts for “re-bracketing,” which is a key step to make recursive programs tail recursive in the general area of program development, from Cooper in the 1960s and onwards.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":" ","pages":""},"PeriodicalIF":1.1,"publicationDate":"2023-02-14","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"48880597","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 1
Programming language semantics: It’s easy as 1,2,3 编程语言语义:就像1、2、3一样简单
3区 计算机科学
Journal of Functional Programming Pub Date : 2023-01-01 DOI: 10.1017/s0956796823000072
GRAHAM HUTTON
{"title":"Programming language semantics: It’s easy as 1,2,3","authors":"GRAHAM HUTTON","doi":"10.1017/s0956796823000072","DOIUrl":"https://doi.org/10.1017/s0956796823000072","url":null,"abstract":"Abstract Programming language semantics is an important topic in theoretical computer science, but one that beginners often find challenging. This article provides a tutorial introduction to the subject, in which the language of integers and addition is used as a minimal setting in which to present a range of semantic concepts in simple manner. In this setting, it is easy as 1,2,3.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"153 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2023-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"134882477","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
A type-directed, dictionary-passing translation of method overloading and structural subtyping in Featherweight Generic Go 轻量级泛型围棋中对方法重载和结构子类型的类型导向、字典传递的翻译
3区 计算机科学
Journal of Functional Programming Pub Date : 2023-01-01 DOI: 10.1017/s0956796823000047
MARTIN SULZMANN, STEFAN WEHR
{"title":"A type-directed, dictionary-passing translation of method overloading and structural subtyping in Featherweight Generic Go","authors":"MARTIN SULZMANN, STEFAN WEHR","doi":"10.1017/s0956796823000047","DOIUrl":"https://doi.org/10.1017/s0956796823000047","url":null,"abstract":"Abstract Featherweight Generic Go (FGG) is a minimal core calculus modeling the essential features of the programming language Go. It includes support for overloaded methods, interface types, structural subtyping, and generics. The most straightforward semantic description of the dynamic behavior of FGG programs is to resolve method calls based on runtime type information of the receiver. This article shows a different approach by defining a type-directed translation from ${textrm{FGG}^{-}}$ to an untyped lambda-calculus. ${textrm{FGG}^{-}}$ includes all features of FGG but type assertions. The translation of an ${textrm{FGG}^{-}}$ program provides evidence for the availability of methods as additional dictionary parameters, similar to the dictionary-passing approach known from Haskell type classes. Then, method calls can be resolved by a simple lookup of the method definition in the dictionary. Every program in the image of the translation has the same dynamic semantics as its source ${textrm{FGG}^{-}}$ program. The proof of this result is based on a syntactic, step-indexed logical relation. The step index ensures a well-founded definition of the relation in the presence of recursive interface types and recursive methods. Although being non-deterministic, the translation is coherent.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"44 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2023-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"136201823","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Normalization by evaluation for modal dependent type theory 模态相关类型理论的求值归一化
3区 计算机科学
Journal of Functional Programming Pub Date : 2023-01-01 DOI: 10.1017/s0956796823000060
JASON Z. S. HU, JUNYOUNG JANG, BRIGITTE PIENTKA
{"title":"Normalization by evaluation for modal dependent type theory","authors":"JASON Z. S. HU, JUNYOUNG JANG, BRIGITTE PIENTKA","doi":"10.1017/s0956796823000060","DOIUrl":"https://doi.org/10.1017/s0956796823000060","url":null,"abstract":"Abstract We present the Kripke-style modal type theory, Mint, which combines dependent types and the necessity modality. It extends the Kripke-style modal lambda-calculus by Pfenning and Davies to the full Martin-Löf type theory. As such it encompasses dependently typed variants of system K, T, K4, and S4. Further, Mint seamlessly supports a full universe hierarchy, usual inductive types, and large eliminations. In this paper, we give a modular sound and complete normalization-by-evaluation (NbE) proof for Mint based on an untyped domain model, which applies to all four aforementioned modal systems without modification. This NbE proof yields a normalization algorithm for Mint, which can be directly implemented. To further strengthen our results, our models and the NbE proof are fully mechanized in Agda and we extract a Haskell implementation of our NbE algorithm from it.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"37 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2023-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"135908024","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 3
Contract lenses: Reasoning about bidirectional programs via calculation 契约透镜:通过计算对双向程序进行推理
3区 计算机科学
Journal of Functional Programming Pub Date : 2023-01-01 DOI: 10.1017/s0956796823000059
HANLIANG ZHANG, WENHAO TANG, RUIFENG XIE, MENG WANG, ZHENJIANG HU
{"title":"Contract lenses: Reasoning about bidirectional programs via calculation","authors":"HANLIANG ZHANG, WENHAO TANG, RUIFENG XIE, MENG WANG, ZHENJIANG HU","doi":"10.1017/s0956796823000059","DOIUrl":"https://doi.org/10.1017/s0956796823000059","url":null,"abstract":"Abstract Bidirectional transformations (BXs) are a mechanism for maintaining consistency between multiple representations of related data. The lens framework, which usually constructs BXs from lens combinators, has become the mainstream approach to BX programming because of its modularity and correctness by construction. However, the involved bidirectional behaviors of lenses make the equational reasoning and optimization of them much harder than unidirectional programs. We propose a novel approach to deriving efficient lenses from clear specifications via program calculation, a correct-by-construction approach to reasoning about functional programs by algebraic laws. To support bidirectional program calculation, we propose contract lenses , which extend conventional lenses with a pair of predicates to enable safe and modular composition of partial lenses. We define several contract-lens combinators capturing common computation patterns including $textit{fold}, textit{filter},textit{map}$ , and $textit{scan}$ , and develop several bidirectional calculation laws to reason about and optimize contract lenses. We demonstrate the effectiveness of our new calculation framework based on contract lenses with nontrivial examples.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":"46 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2023-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"135449658","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Modal FRP for all: Functional reactive programming without space leaks in Haskell Modal FRP for all: Haskell中没有空间泄漏的函数式响应式编程
IF 1.1 3区 计算机科学
Journal of Functional Programming Pub Date : 2022-12-26 DOI: 10.1017/S0956796822000132
P. Bahr
{"title":"Modal FRP for all: Functional reactive programming without space leaks in Haskell","authors":"P. Bahr","doi":"10.1017/S0956796822000132","DOIUrl":"https://doi.org/10.1017/S0956796822000132","url":null,"abstract":"Abstract Functional reactive programming (FRP) provides a high-level interface for implementing reactive systems in a declarative manner. However, this high-level interface has to be carefully reigned in to ensure that programs can in fact be executed in practice. Specifically, one must ensure that FRP programs are causal and can be implemented without introducing space leaks. In recent years, modal types have been demonstrated to be an effective tool to ensure these operational properties. In this paper, we present \u0000$mathsf{Rattus}$\u0000 , a modal FRP language that extends and simplifies previous modal FRP calculi while still maintaining the operational guarantees for productivity, causality, and space leaks. The simplified type system makes \u0000$mathsf{Rattus}$\u0000 a practical programming language that can be integrated with existing functional programming languages. To demonstrate this, we have implemented a shallow embedding of \u0000$mathsf{Rattus}$\u0000 in Haskell that allows the programmer to write \u0000$mathsf{Rattus}$\u0000 code in familiar Haskell syntax and seamlessly integrate it with regular Haskell code. Thus, \u0000$mathsf{Rattus}$\u0000 combines the benefits enjoyed by FRP libraries such as Yampa, namely access to a rich library ecosystem (e.g., for graphics programming), with the strong operational guarantees offered by a bespoke type system. To establish the productivity, causality, and memory properties of the language, we prove type soundness using a logical relations argument fully mechanised in the Coq proof assistant.","PeriodicalId":15874,"journal":{"name":"Journal of Functional Programming","volume":" ","pages":""},"PeriodicalIF":1.1,"publicationDate":"2022-12-26","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"41911001","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":3,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 3
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
相关产品
×
本文献相关产品
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信