Programming and Proving with Indexed Effects - Inria - Institut national de recherche en sciences et technologies du numérique Accéder directement au contenu
Rapport (Rapport Technique) Année : 2020

Programming and Proving with Indexed Effects

Résumé

Proving properties about effectful programs is hard. New application-specific abstractions based on indexed monads can help simplify programming and proving. However, existing languages lack support to develop and use such abstractions. The main contribution of this paper is a type-and-effect system that enables program proof developers to design new effect-typing disciplines based on indexed monads, making proofs simpler and more abstract and allowing programs to be developed in a direct, applicative syntax while automatically elaborating them into a core language of pure, total functions where the monadic structure is made explicit. We have implemented our system as a new feature in the F ★ programming language, enhancing its existing user-defined effect system to cover all forms of indexed monads. In doing so, we have also simplified the core language of F ★ , allowing us to derive basic Dijkstra monad constructions in F ★ that were previously primitive. Finally, we present several case studies developing new indexed monad constructions to structure program proofs in settings including information flow control, algebraic effects, and low-level binary format parsers.
Fichier principal
Vignette du fichier
indexedeffects.pdf (558.93 Ko) Télécharger le fichier
Origine : Fichiers produits par l'(les) auteur(s)

Dates et versions

hal-04256360 , version 1 (24-10-2023)

Licence

Paternité

Identifiants

  • HAL Id : hal-04256360 , version 1

Citer

Aseem Rastogi, Guido Martínez, Aymeric Fromherz, Tahina Ramananandro, Nikhil Swamy. Programming and Proving with Indexed Effects. Microsoft Research. 2020. ⟨hal-04256360⟩

Collections

INRIA INRIA2 LARA
17 Consultations
10 Téléchargements

Partager

Gmail Facebook X LinkedIn More