Logic in Computer Science. Huth, M. & Ryan, M. Volume 2142 of Lecture Notes in Computer Science, Cambridge, 2004.
Logic in Computer Science [pdf]Website  abstract   bibtex   
We describe an extension of Hoares logic for reasoning about programs that alter data structures. We consider a low-level storage model based on a heap with associated lookup, update, allocation and deallocation operations, and unrestricted address arithmetic. The assertion language is based on a possible worlds model of the logic of bunched implications, and includes spatial conjunction and implication connectives alongside those of classical logic. Heap operations are axiomatized using what we call the small axioms , each of which mentions only those cells accessed by a particular command. Through these and a number of examples we show that the formalism supports local reasoning: A specification and proof can concentrate on only those cells in memory that a program accesses. This paper builds on earlier work by Burstall, Reynolds, Ishtiaq and OHearn on reasoning about data structures.

Downloads: 0