Repository logo
 

Extended Call-by-Push-Value: Reasoning About Effectful Programs and Evaluation Order

Accepted version
Peer-reviewed

Type

Conference Object

Change log

Abstract

Traditionally, reasoning about programs under varying evaluation regimes (call-by-value, call-by-name etc.) was done at the meta-level, treating them as term rewriting systems. Levy’s call-by-push-value (CBPV) calculus provides a more powerful approach for reasoning, by treating CBPV terms as a common intermediate language which captures both call-by-value and call-by-name, and by allowing equational reasoning about changes to evaluation order between or within programs.

We extend CBPV to additionally deal with call-by-need, which is non-trivial because of shared reductions. This allows the equational reasoning to also support call-by-need. As an example, we then prove that call-by-need and call-by-name are equivalent if nontermination is the only side-effect in the source language.

We then show how to incorporate an effect system. This enables us to exploit static knowledge of the potential effects of a given expression to augment equational reasoning; thus a program fragment might be invariant under change of evaluation regime only because of knowledge of its effects.

Description

Keywords

Evaluation order, Call-by-need, Call-by-push-value, Logical relations, Effect systems

Journal Title

Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)

Conference Name

ESOP 2019

Journal ISSN

0302-9743
1611-3349

Volume Title

11423 LNCS

Publisher

Springer International Publishing
Sponsorship
EPSRC (1789520)