## Abstract

We describe an axiomatic extension to the Coq proof assistant, that supports writing, reasoning about, and extracting higher-order, dependently-typed programs with side-effects. Coq already includes a powerful functional language that supports dependent types, but that language is limited to pure, total functions. The key contribution of our extension, which we call Ynot, is the added support for computations that may have effects such as non-termination, accessing a mutable store, and throwing/catching exceptions.

The axioms of Ynot form a small trusted computing base which has been formally justified in our previous work on Hoare Type Theory (HTT). We show how these axioms can be combined with the powerful type and abstraction mechanisms of Coq to build higher-level reasoning mechanisms which in turn can be used to build realistic, verified software components. To substantiate this claim, we describe here a representative series of modules that

implement imperative finite maps, including support for a higherorder (effectful) iterator. The implementations range from simple (e.g., association lists) to complex (e.g., hash tables) but share a common interface which abstracts the implementation details and ensures that the modules properly implement the finite map abstraction.

The axioms of Ynot form a small trusted computing base which has been formally justified in our previous work on Hoare Type Theory (HTT). We show how these axioms can be combined with the powerful type and abstraction mechanisms of Coq to build higher-level reasoning mechanisms which in turn can be used to build realistic, verified software components. To substantiate this claim, we describe here a representative series of modules that

implement imperative finite maps, including support for a higherorder (effectful) iterator. The implementations range from simple (e.g., association lists) to complex (e.g., hash tables) but share a common interface which abstracts the implementation details and ensures that the modules properly implement the finite map abstraction.

Originalsprog | Engelsk |
---|---|

Titel | International Conference on Functional Programming : Proceeding of the 13th ACM SIGPLAN International Conference on Functional Programming, |

Vol/bind | session 9 |

Forlag | Association for Computing Machinery |

Publikationsdato | 2008 |

Sider | 229-240 |

ISBN (Trykt) | 978-1-59593-919-7 |

Status | Udgivet - 2008 |

Begivenhed | ICFP 2008 : The 13th ACM SIGPLAN International Conference on Functional Programming - Victoria, British Columbia, Canada Varighed: 22 sep. 2008 → 24 sep. 2008 Konferencens nummer: 13 |

### Konference

Konference | ICFP 2008 : The 13th ACM SIGPLAN International Conference on Functional Programming |
---|---|

Nummer | 13 |

Land/Område | Canada |

By | Victoria, British Columbia |

Periode | 22/09/2008 → 24/09/2008 |

## Emneord

- Coq proof assistant
- Dependent types
- Side-effects
- Hoare Type Theory
- Verified software components