We employ the narrowing-based execution mechanism of the functional logic programming language Curry in order to automatically generate a system of test cases for glass-box testing of Curry programs. the test cases fo...
详细信息
We present a framework of dynamic programming combinators that provides a high-level environment to describe the recursions typical of dynamic programming over sequence data in a style very similar to algebraic dynami...
详细信息
Generic programming language constructs, tools and libraries have been available in Haskell since the first report on the programming language Haskell. At the beginning of the 1990s generic programming techniques coul...
详细信息
ISBN:
(纸本)9781450323895
Generic programming language constructs, tools and libraries have been available in Haskell since the first report on the programming language Haskell. At the beginning of the 1990s generic programming techniques could be used via the deriving construct, and since then numerous generic programming libraries and tools have been developed. At the time of writing, the categories 'generic' and 'generics' on Hackage, the online repository of Haskell software, contain 53 packages. Although not all of these are generic programming libraries or tools, there are many approaches to generic programming to choose from. this brief paper discusses an analysis of the usage of generic programming language constructs, tools, and libraries. We analyse how often which language constructs, tools, and libraries are used on Hackage, how often class instances are derived generically or written manually, and for some libraries, how often the functions that appear in these libraries are used.
We design and implement a library for adding backtracking computations to any Haskell monad. Inspired by logic programming, our library provides, in addition to the operations required by the MonadPlus interface, cons...
详细信息
In a language with non-parametric or ad-hoc polymorphism, it is possible to determine the identity of a type variable at run time. Withthis facility, we can write a function to convert a term from one abstract type t...
详细信息
In a language with non-parametric or ad-hoc polymorphism, it is possible to determine the identity of a type variable at run time. Withthis facility, we can write a function to convert a term from one abstract type to another, if the two hidden types are identical. However, the naive implementation of this function requires that the term be destructed and rebuilt. In this paper, we show how to eliminate this overhead using higher-order type abstraction. We demonstrate this solution in two frameworks for ad-hoc polymorphism: intensional type analysis and type classes.
the proceedings contain 6 papers. the topics discussed include: Bluespec and Haskell;functional synthesis of genetic regulatory networks;encoding secure information flow with restricted delegation and revocation in Ha...
ISBN:
(纸本)9781450323802
the proceedings contain 6 papers. the topics discussed include: Bluespec and Haskell;functional synthesis of genetic regulatory networks;encoding secure information flow with restricted delegation and revocation in Haskell;QuaFL: a typed DSL for quantum programming;embrace, defend, extend: a methodology for embedding preexisting DSLs: case in point, StreamHs: StreamIT in Haskell;abstract resource cost derivation for logical quantum circuit descriptions;and sensitivity analysis using type-based constraints.
Implementing first-class continuations can pose a challenge if the target machine makes no provisions for accessing and re-installing the run-time stack. In this paper, we present a novel translation that overcomes th...
详细信息
ISBN:
(纸本)9781595930644
Implementing first-class continuations can pose a challenge if the target machine makes no provisions for accessing and re-installing the run-time stack. In this paper, we present a novel translation that overcomes this problem. In the first half of the paper, we introduce a theoretical model that shows how to eliminate the capture and the use of first-class continuations in the presence of a generalized stack inspection mechanism. the second half of the paper explains how to translate this model into practice in two different contexts. First, we reformulate the servlet interaction language in the PLT Web server, which heavily relies on first-class continuations. Using our technique, servlet programs can be run directly under the control of non-cooperative web servers such as Apache. Second, we show how to use our new technique to copy and reconstitute the stack on *** using exception handlers. this establishes that Scheme's first-class continuations can exist on non-cooperative virtual machines.
Combining type theory, language design, and empirical work, we present techniques for computing with large and dynamically changing datasets. Based on lambda calculus, our techniques are suitable for expressing a dive...
详细信息
ISBN:
(纸本)9781450328739
Combining type theory, language design, and empirical work, we present techniques for computing with large and dynamically changing datasets. Based on lambda calculus, our techniques are suitable for expressing a diverse set of algorithms on large datasets and, via self-adjusting computation, enable computations to respond automatically to changes in their data. To improve the scalability of self-adjusting computation, we present a type system for precise dependency tracking that minimizes the time and space for storing dependency metadata. the type system eliminates an important assumption of prior work that can lead to recording spurious dependencies. We present a type-directed translation algorithm that generates correct self-adjusting programs without relying on this assumption. We then show a probabilistic-chunking technique to further decrease space usage by controlling the fundamental space-time tradeoff in self-adjusting computation. We implement and evaluate these techniques, showing promising results on challenging benchmarks involving large graphs.
Dependently typed languages allow programmers to state and prove type class laws by simply encoding the laws as class methods. But writing implementations of these methods frequently give way to large amounts of routi...
详细信息
ISBN:
(纸本)9781450368131
Dependently typed languages allow programmers to state and prove type class laws by simply encoding the laws as class methods. But writing implementations of these methods frequently give way to large amounts of routine, boilerplate code, and depending on the law involved, the size of these proofs can grow superlinearly withthe size of the datatypes involved. We present a technique for automating away large swaths of this boilerplate by leveraging datatype-generic programming. We observe that any algebraic data type has an equivalent representation type that is composed of simpler, smaller types that are simpler to prove theorems over. By constructing an isomorphism between a datatype and its representation type, we derive proofs for the original datatype by reusing the corresponding proof over the representation type. Our work is designed to be general-purpose and does not require advanced automation techniques such as tactic systems. As evidence for this claim, we implement these ideas in a Haskell library that defines generic, canonical implementations of the methods and proof obligations for classes in the standard base library.
this paper reports the implementation of Emfrp-REPL, an interactive interpreter (REPL) of a functional reactive programming language for resource-constrained embedded systems. Its goal is to accelerate the prototyping...
详细信息
ISBN:
(纸本)9798400707551
this paper reports the implementation of Emfrp-REPL, an interactive interpreter (REPL) of a functional reactive programming language for resource-constrained embedded systems. Its goal is to accelerate the prototyping and development of microcontroller-based embedded systems. the interpreter runs on small-scale embedded devices based on 32-bit microcontrollers, such as ESP32 with 520KiB size data RAM. the evaluation shows that the memory usage of Emfrp-REPL is comparable to MicroPython, and the range of its latency is narrower than MicroPython, according to microbenchmarks.
暂无评论