Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell最新文献

筛选
英文 中文
Elaboration on functional dependencies: functional dependencies are dead, long live functional dependencies! 详细阐述功能依赖:功能依赖已死,功能依赖万岁!
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122966
G. Karachalias, T. Schrijvers
{"title":"Elaboration on functional dependencies: functional dependencies are dead, long live functional dependencies!","authors":"G. Karachalias, T. Schrijvers","doi":"10.1145/3122955.3122966","DOIUrl":"https://doi.org/10.1145/3122955.3122966","url":null,"abstract":"Functional dependencies are a popular extension to Haskell's type-class system because they provide fine-grained control over type inference, resolve ambiguities and even enable type-level computations. Unfortunately, several aspects of Haskell's functional dependencies are ill-understood. In particular, the GHC compiler does not properly enforce the functional dependency property, and rejects well-typed programs because it does not know how to elaborate them into its core language, System FC. This paper presents a novel formalization of functional dependencies that addresses these issues: We explicitly capture the functional dependency property in the type system, in the form of explicit type equalities. We also provide a type inference algorithm and an accompanying elaboration strategy which allows all well-typed programs to be elaborated into System FC.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"19 4-5","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"120890309","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 6
Back to the future: time travel in FRP 回到未来:在FRP时间旅行
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122957
Ivan Perez
{"title":"Back to the future: time travel in FRP","authors":"Ivan Perez","doi":"10.1145/3122955.3122957","DOIUrl":"https://doi.org/10.1145/3122955.3122957","url":null,"abstract":"Functional Reactive Programming (FRP) allows interactive applications to be modelled in a declarative manner using time-varying values. For practical reasons, however, operational constraints are often imposed, such as having a fixed time domain, time always flowing forward, and limiting the exploration of the past. In this paper we show how these constraints can be overcome, giving local control over the time domain, the direction of time and the sampling step. We study the behaviour of FRP expressions when time flows backwards, and demonstrate how to synchronize subsystems running asynchronously and at different sampling rates. We have verified the practicality of our approach with two non-trivial games in which time control is central to the gameplay.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"43 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"126914451","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 14
Well-typed music does not sound wrong (experience report) 体裁好的音乐听起来不会错(体验报告)
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122964
Dmitrij Szamozvancev, Michael B. Gale
{"title":"Well-typed music does not sound wrong (experience report)","authors":"Dmitrij Szamozvancev, Michael B. Gale","doi":"10.1145/3122955.3122964","DOIUrl":"https://doi.org/10.1145/3122955.3122964","url":null,"abstract":"Music description and generation are popular use cases for Haskell, ranging from live coding libraries to automatic harmonisation systems. Some approaches use probabilistic methods, others build on the theory of Western music composition, but there has been little work done on checking the correctness of musical pieces in terms of voice leading, harmony, and structure. Haskell's recent additions to the type-system now enable us to perform such analysis statically. We present our experience of implementing a type-level model of classical music and an accompanying EDSL which enforce the rules of classical music at compile-time, turning composition mistakes into compiler errors. Along the way, we discuss the strengths and limitations of doing this in Haskell and demonstrate that the type system of the language is fully capable of expressing non-trivial and practical logic specific to a particular domain.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"167 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"116299787","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 4
QuickSpec: a lightweight theory exploration tool for programmers (system demonstration) QuickSpec:面向程序员的轻量级理论探索工具(系统演示)
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122960
Maximilian Algehed, Koen Claessen, Moa Johansson, Nicholas Smallbone
{"title":"QuickSpec: a lightweight theory exploration tool for programmers (system demonstration)","authors":"Maximilian Algehed, Koen Claessen, Moa Johansson, Nicholas Smallbone","doi":"10.1145/3122955.3122960","DOIUrl":"https://doi.org/10.1145/3122955.3122960","url":null,"abstract":"This document gives the outline of a system demonstration for the QuickSpec theory exploration tool.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"163 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"133593102","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 0
Ornaments: exploiting parametricity for safer, more automated code refactorization and code reuse (invited talk) 装饰:利用参数来实现更安全、更自动化的代码重构和代码重用(特邀演讲)
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3127333
Didier Rémy
{"title":"Ornaments: exploiting parametricity for safer, more automated code refactorization and code reuse (invited talk)","authors":"Didier Rémy","doi":"10.1145/3122955.3127333","DOIUrl":"https://doi.org/10.1145/3122955.3127333","url":null,"abstract":"Inductive datatypes and parametric polymorphism are two key features introduced in the ML family of languages, which have already been widely exploited for structuring programs: Haskell and ML programs are often more elegant and more correct by construction. Still, we sometimes need code to be refactored or adapted to be reused in a slightly different context. While the type system is considerably helpful in these situations, by automatically locating type-inconsistent program points or incomplete pattern matchings, this process could be made safer and more automated by further exploiting parametricity. We propose a posteriori program abstraction as a principle for such code transformations. We apply this principle to ornamentation which is a way to describe changes in datatype definitions reorganizing, adding, or dropping some pieces of data so that functions operating on the bare definition can be partially and sometimes totally lifted into functions operating on the ornamented structure. We view ornamentation as an a posteriori abstraction of the bare code, called a generic lifting, which can then be instantiated into a concrete lifting, meta-reduced, and simplified. Both the source and target code live in core ML while the lifted code lives in a meta-language above ML equipped with a limited form of dependent types needed to capture some invariants of the generic lifting so that the concrete lifting can be simplified back into an ML program. Importantly, the lifted code can be closely related to the bare code, using logical relations thanks to the generic lifting detour. Different, typical use cases of ornaments will be shown and the approach will be mainly illustrated on examples.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"407 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"116386757","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 2
A meta-EDSL for distributed web applications 用于分布式web应用程序的元edsl
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122969
A. Ekblad
{"title":"A meta-EDSL for distributed web applications","authors":"A. Ekblad","doi":"10.1145/3122955.3122969","DOIUrl":"https://doi.org/10.1145/3122955.3122969","url":null,"abstract":"We present a domain-specific language for constructing and configuring web applications distributed across any number of networked, heterogeneous systems. Our language is embedded in Haskell, provides a common framework for integrating components written in third-party EDSLs, and enables type-safe, access-controlled communication between nodes, as well as effortless sharing and movement of functionality between application components. We give an implementation of our language and demonstrate its applicability by using it to implement several important components of distributed web applications, including RDBMS integration, load balancing, and fine-grained sandboxing of untrusted third party code. The rising popularity of cloud computing and heterogeneous computer architectures is putting a strain on conventional programming models, which commonly assume that one application executes on one machine, or at best on one out of several identical machines. With our language, we take the first step towards a programming model better suited for a computationally multicultural future.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"5 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"123614777","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 5
Composable network stacks and remote monads 可组合的网络栈和远程单子
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122968
Justin Dawson, Mark Grebe, Andy Gill
{"title":"Composable network stacks and remote monads","authors":"Justin Dawson, Mark Grebe, Andy Gill","doi":"10.1145/3122955.3122968","DOIUrl":"https://doi.org/10.1145/3122955.3122968","url":null,"abstract":"Monads and applicative functors are two ways that Haskell programmers bundle effectful primitives into effectful program fragments. In this paper, we investigate using monads and applicative functors to bundle remote effectful primitives, specifically aiming to amortize the cost of remote communications using bundling. We look at several ways of maximizing the bundling of primitives, drawing from the remote monad design pattern and Haxl system, and provide a taxonomy of mechanism for amortization, with examples. The result of this investigation is that monadic fragments can be efficiently bundled into packets, almost for free, when given a user-supplied packet transportation mechanism, and the primitives obey some simple pre- and post-conditions.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"112 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"122608196","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 2
Quantified class constraints 量化的类约束
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122967
G. Bottu, G. Karachalias, T. Schrijvers, B. C. D. S. Oliveira, P. Wadler
{"title":"Quantified class constraints","authors":"G. Bottu, G. Karachalias, T. Schrijvers, B. C. D. S. Oliveira, P. Wadler","doi":"10.1145/3122955.3122967","DOIUrl":"https://doi.org/10.1145/3122955.3122967","url":null,"abstract":"Quantified class constraints have been proposed many years ago to raise the expressive power of type classes from Horn clauses to the universal fragment of Hereditiary Harrop logic. Yet, while it has been much asked for over the years, the feature was never implemented or studied in depth. Instead, several workarounds have been proposed, all of which are ultimately stopgap measures. This paper revisits the idea of quantified class constraints and elaborates it into a practical language design. We show the merit of quantified class constraints in terms of more expressive modeling and in terms of terminating type class resolution. In addition, we provide a declarative specification of the type system as well as a type inference algorithm that elaborates into System F. Moreover, we discuss termination conditions of our system and also provide a prototype implementation.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"25 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"116692902","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 28
Hardware software co-design in Haskell Haskell中的硬件软件协同设计
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122970
Markus Aronsson, M. Sheeran
{"title":"Hardware software co-design in Haskell","authors":"Markus Aronsson, M. Sheeran","doi":"10.1145/3122955.3122970","DOIUrl":"https://doi.org/10.1145/3122955.3122970","url":null,"abstract":"We present a library in Haskell for programming Field Programmable Gate Arrays (FPGAs), including hardware software co-design. Code for software (in C) and hardware (in VHDL) is generated from a single program, along with the code to support communication between hardware and software. We present type-based techniques for the simultaneous implementation of more than one embedded domain specific language (EDSL). We build upon a generic representation of imperative programs that is loosely coupled to instruction and expression types, allowing the individual parts to be developed and improved separately. Code generation is implemented as a series of translations between progressively smaller, typed EDSLs, safeguarding against errors that arise in untyped translations. Initial case studies show promising performance.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"1 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"129505106","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 7
Algebraic graphs with class (functional pearl) 一类代数图(泛函珍珠)
Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell Pub Date : 2017-09-07 DOI: 10.1145/3122955.3122956
A. Mokhov
{"title":"Algebraic graphs with class (functional pearl)","authors":"A. Mokhov","doi":"10.1145/3122955.3122956","DOIUrl":"https://doi.org/10.1145/3122955.3122956","url":null,"abstract":"The paper presents a minimalistic and elegant approach to working with graphs in Haskell. It is built on a rigorous mathematical foundation --- an algebra of graphs --- that allows us to apply equational reasoning for proving the correctness of graph transformation algorithms. Algebraic graphs let us avoid partial functions typically caused by `malformed graphs' that contain an edge referring to a non-existent vertex. This helps to liberate APIs of existing graph libraries from partial functions. The algebra of graphs can represent directed, undirected, reflexive and transitive graphs, as well as hypergraphs, by appropriately choosing the set of underlying axioms. The flexibility of the approach is demonstrated by developing a library for constructing and transforming polymorphic graphs.","PeriodicalId":312246,"journal":{"name":"Proceedings of the 10th ACM SIGPLAN International Symposium on Haskell","volume":"20 1","pages":"0"},"PeriodicalIF":0.0,"publicationDate":"2017-09-07","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":null,"resultStr":null,"platform":"Semanticscholar","paperid":"115127775","PeriodicalName":null,"FirstCategoryId":null,"ListUrlMain":null,"RegionNum":0,"RegionCategory":"","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":"","EPubDate":null,"PubModel":null,"JCR":null,"JCRName":null,"Score":null,"Total":0}
引用次数: 16
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学术文献互助群
群 号:604180095
Book学术官方微信
小红书