Abstract
Laws in the Miranda programming language provide a means of implementing non-free algebraic types, by means of term rewriting. In this paper we investigate program verification in such a context. Specifically, we look at how to deduce properties of functions over these “lawful” types. After examining the general problem, we look at a particular class of functions, the faithful functions. For such functions we are able, in a direct manner, to transfer properties of functions from free types to non-free types. We introduce sufficient model theory to explain these transfer results, and then find characterisations of various classes of faithful functions. Then we investigate an application of this technique to general, unfaithful, situations. In conclusion we survey Wadler's work on views and assess the utility of laws and views.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.