Abstract
Hoare and He’s unifying theories of programming (UTP) provide a collection of relational models that can be used to study and compare several programming paradigms. In this paper, we add to the UTP a theory of pointers and records that provides a model for objects and sharing in languages like Java and C++. Our work is based on the hierarchical addressing scheme used to refer to record fields (or object attributes) in conventional languages, rather than explicit notions of location. More importantly, we support reasoning about the structure and sharing of data, as well as their, possibly infinite, values. We also provide a general account of UTP theories characterised by conjunctive healthiness conditions, of which our theory is an example.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Back, R.J., Fan, X., Preoteasa, V.: Reasoning about Pointers in Refinement Calculus. In: APSEC 2003, p. 425. IEEE Computer Society Press, Los Alamitos (2003)
Bakewell, A., Plump, D., Runciman, C.: Specifying Pointer Structures by Graph Reduction. In: Pfaltz, J.L., Nagl, M., Böhlen, B. (eds.) AGTIVE 2003. LNCS, vol. 3062, pp. 30–44. Springer, Heidelberg (2004)
Brookes, S.D.: A Fully Abstract Semantics and a Proof System for an Algol-like Language with Sharing. In: Melton, A. (ed.) MFPS 1985. LNCS, vol. 239, pp. 59–100. Springer, Heidelberg (1986)
Burstall, R.M.: Some techniques for proving correctness of programs which alter data structures. Machine Intelligence 7, 23–50 (1972)
Cavalcanti, A.L.C., Harwood, W., Woodcock, J.C.P.: Pointers and Records in the Unifying Theories of Programming. In: Dunne, S., Stoddart, B. (eds.) UTP 2006. LNCS, vol. 4010, pp. 200–216. Springer, Heidelberg (2006)
Cavalcanti, A.L.C., Sampaio, A.C.A., Woodcock, J.C.P.: Unifying Classes and Processes. SoSyM 4(3), 277–296 (2005)
Cavalcanti, A.L.C., Woodcock, J.C.P.: A Tutorial Introduction to CSP in Unifying Theories of Programming. In: Cavalcanti, A., Sampaio, A., Woodcock, J. (eds.) PSSE 2004. LNCS, vol. 3167, pp. 220–268. Springer, Heidelberg (2006)
Chen, Y., Sanders, J.: Compositional Reasoning for Pointer Structures. In: Uustalu, T. (ed.) MPC 2006. LNCS, vol. 4014, pp. 115–139. Springer, Heidelberg (2006)
Desharnais, J., Möller, B., Struth, G.: Modal Kleene Algebra and applications a survey. Methods in Computer Science 1, 93–131 (2004)
Harwood, W., Cavalcanti, A.L.C., Woodcock, J.C.P.: A Model of Pointers for the Unifying Theories of Programming – Extended Version. Technical report, University of York, Department of Computer Science, UK (2008), www-users.cs.york.ac.uk/~alcc/publications/HCW08.pdf
Hoare, C.A.R., Jifeng, H.: Unifying Theories of Programming. In: Unifying Theories of Programming. Prentice-Hall, Englewood Cliffs (1998)
Hoare, C.A.R., Jifeng, H.: A trace model for pointers and objects. Programming methodology, 223 – 245 (2003)
Ishtiaq, S., O’Hearn, P.W.: BI as an assertion language for mutable data structures. In: POPL. ACM Press, New York (2001)
Liu, Z., He, J., Li, X.: rCOS: Refinement of Component and Object Systems. In: de Boer, F.S., Bonsangue, M.M., Graf, S., de Roever, W.-P. (eds.) FMCO 2004. LNCS, vol. 3657, Springer, Heidelberg (2005)
Meyer, B.: Eiffel: the language. Prentice-Hall, Englewood Cliffs (1992)
Meyer, B.: Towards practical proofs of class correctness. In: Bert, D., P. Bowen, J., King, S. (eds.) ZB 2003. LNCS, vol. 2651, pp. 359–387. Springer, Heidelberg (2003)
Milne, R., Strachey, C.: A Theory of Programming Language Semantics. Chapman and Hall, Boca Raton (1976)
Möller, B.: Calculating with pointer structures. In: IFIP TC 2 WG 2.1 International Workshop on Algorithmic Languages and Calculi, pp. 24–48. Chapman & Hall, Ltd, Boca Raton (1997)
Naumann, D.A.: Predicate Transformer Semantics of a Higher Order Imperative Language with Record Subtypes. SCP 41(1), 1–51 (2001)
O’Hearn, P., Reynolds, J., Yang, H.: Local reasoning about programs that alter data structures. In: Fribourg, L. (ed.) CSL 2001 and EACSL 2001. LNCS, vol. 2142, pp. 1–19. Springer, Heidelberg (2001)
Paige, R.F., Ostroff, J.S.: ERC – An object-oriented refinement calculus for Eiffel. Formal Aspects of Computing 16(1), 5 (2004)
Qin, S., Dong, J.S., Chin, W.N.: A Semantic Foundation for TCOZ in Unifying Theories of Programming. In: Araki, K., Gnesi, S., Mandrioli, D. (eds.) FME 2003. LNCS, vol. 2805, pp. 321–340. Springer, Heidelberg (2003)
Reynolds, J.: Separation logic: a logic for shared mutable data structures. In: IEEE Symposium on Logic in Computer Science, pp. 55–74. IEEE Press, Los Alamitos (2002)
Reynolds, J.C.: Intuitionistic reasoning about shared mutable data structure. In: Millenial Perspectives in Computer Science. Palgrave (2001)
Santos, T.L.V.L., Cavalcanti, A.L.C., Sampaio, A.C.A.: Object Orientation in the UTP. In: Dunne, S., Stoddart, B. (eds.) UTP 2006. LNCS, vol. 4010, pp. 18–37. Springer, Heidelberg (2006)
Smith, G.: The Object-Z Specification Language. Kluwer Academic Publishers, Dordrecht (1999)
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 2008 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Harwood, W., Cavalcanti, A., Woodcock, J. (2008). A Theory of Pointers for the UTP. In: Fitzgerald, J.S., Haxthausen, A.E., Yenigun, H. (eds) Theoretical Aspects of Computing - ICTAC 2008. ICTAC 2008. Lecture Notes in Computer Science, vol 5160. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-85762-4_10
Download citation
DOI: https://doi.org/10.1007/978-3-540-85762-4_10
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-85761-7
Online ISBN: 978-3-540-85762-4
eBook Packages: Computer ScienceComputer Science (R0)