439 research outputs found
Practical Subtyping for System F with Sized (Co-)Induction
We present a rich type system with subtyping for an extension of System F.
Our type constructors include sum and product types, universal and existential
quantifiers, inductive and coinductive types. The latter two size annotations
allowing the preservation of size invariants. For example it is possible to
derive the termination of the quicksort by showing that partitioning a list
does not increase its size. The system deals with complex programs involving
mixed induction and coinduction, or even mixed (co-)induction and polymorphism
(as for Scott-encoded datatypes). One of the key ideas is to completely
separate the induction on sizes from the notion of recursive programs. We use
the size change principle to check that the proof is well-founded, not that the
program terminates. Termination is obtained by a strong normalization proof.
Another key idea is the use symbolic witnesses to handle quantifiers of all
sorts. To demonstrate the practicality of our system, we provide an
implementation that accepts all the examples discussed in the paper and much
more
Logical relations for coherence of effect subtyping
A coercion semantics of a programming language with subtyping is typically
defined on typing derivations rather than on typing judgments. To avoid
semantic ambiguity, such a semantics is expected to be coherent, i.e.,
independent of the typing derivation for a given typing judgment. In this
article we present heterogeneous, biorthogonal, step-indexed logical relations
for establishing the coherence of coercion semantics of programming languages
with subtyping. To illustrate the effectiveness of the proof method, we develop
a proof of coherence of a type-directed, selective CPS translation from a typed
call-by-value lambda calculus with delimited continuations and control-effect
subtyping. The article is accompanied by a Coq formalization that relies on a
novel shallow embedding of a logic for reasoning about step-indexing
PML2: Integrated Program Verification in ML
We present the PML_2 language, which provides a uniform environment for programming, and for proving properties of programs in an ML-like setting. The language is Curry-style and call-by-value, it provides a control operator (interpreted in terms of classical logic), it supports general recursion and a very general form of (implicit, non-coercive) subtyping. In the system, equational properties of programs are expressed using two new type formers, and they are proved by constructing terminating programs. Although proofs rely heavily on equational reasoning, equalities are exclusively managed by the type-checker. This means that the user only has to choose which equality to use, and not where to use it, as is usually done in mathematical proofs. In the system, writing proofs mostly amounts to applying lemmas (possibly recursive function calls), and to perform case analyses (pattern matchings)
Type Classes for Lightweight Substructural Types
Linear and substructural types are powerful tools, but adding them to
standard functional programming languages often means introducing extra
annotations and typing machinery. We propose a lightweight substructural type
system design that recasts the structural rules of weakening and contraction as
type classes; we demonstrate this design in a prototype language, Clamp.
Clamp supports polymorphic substructural types as well as an expressive
system of mutable references. At the same time, it adds little additional
overhead to a standard Damas-Hindley-Milner type system enriched with type
classes. We have established type safety for the core model and implemented a
type checker with type inference in Haskell.Comment: In Proceedings LINEARITY 2014, arXiv:1502.0441
Programmiersprachen und Rechenkonzepte
Seit 1984 veranstaltet die GI--Fachgruppe "Programmiersprachen und Rechenkonzepte" regelmäßig im Frühjahr einen Workshop im Physikzentrum Bad Honnef. Das Treffen dient in erster Linie dem gegenseitigen Kennenlernen, dem Erfahrungsaustausch, der Diskussion und der Vertiefung gegenseitiger Kontakte
Introduction to the Literature on Semantics
An introduction to the literature on semantics. Included are pointers to the literature on axiomatic semantics, denotational semantics, operational semantics, and type theory
- …