Graph types
Nils Klarlund, Michael I. Schwartzbach · ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL) · 1993
Recursive data structures are abstractions of simple records and pointers. They impose a shape invariant, which is verified at compile-time and exploited to automatically generate code for building, copying, comparing, and traversing values without loss of efficiency. However, such values are always tree shaped, which is a major obstacle to practical use.We propose a notion of graph types, which allow common shapes, such as doubly-linked lists or threaded trees, to be expressed concisely and efficiently. We define regular languages of routing expressions to specify relative addresses of extra pointers in a canonical spanning tree. An efficient algorithm for computing such addresses is developed. We employ a second-order monadic logic to decide well-formedness of graph type specifications. This logic can also be used for automated reasoning about pointer structures.
Cited by 140 works. doi:10.1145/158511.158628
Authors
References
- The Definition of Standard ML
- Miranda: A non-strict functional language with polymorphic types
- Login: a logic programming language with built-in inheritance
- The monadic second-order logic of graphs. I. Recognizable sets of finite graphs
- Recursive data structures
- Abstractions for recursive pointer data structures
- Logic and inheritance
- Towards a meaning of LIFE
- On subsumption and semiunification in feature algebras
- Incremental evaluation for attribute grammars with unrestricted movement between tree modifications