A Correctness Proof for Warren's HO into FO Translation
نویسنده
چکیده
In 16], Warren suggested a method for embedding higher-order (HO) programming constructs into Prolog, that can be viewed as a kind of higher-order into rst-order (FO) translation. This method has been used in diierent settings as a tool for the combination of functional and logic programming 3, 2, 1], or even for the reduction of the former to the later 4]. The present paper was motivated by our feeling that the semantic correctness of Warren's translation is not yet suuciently well understood. We give a formulation of the method in the framework of the HO functional logic language SFL 6, 7], which uses conditional narrowing as operational semantics and has also a well deened declarative semantics. We show that HO SFL programs can be translated into FO SFL programs in such a way that both the declarative and the narrowing semantics are preserved. As a consequence, narrowing strategies which are sound and complete for FO SFL programs can be automatically transferred to HO SFL programs, via the translation.
منابع مشابه
Correctness Proof For the WAM with Types
We provide a mathematical speciication of an extension of Warren's Abstract Machine for executing Prolog to type-constraint logic programming and prove its correctness. In this paper, we keep the notion of types and dynamic type constraints rather abstract to allow applications to diierent constraint formalisms like Prolog III or CLP(R). This generality permits us to introduce modular extension...
متن کاملProof-Theoretic Foundation of Compilation in Logic Programming
Commercial implementations of logic programming languages are engineered around a compiler based on Warren's Abstract Machine (WAM) or a variant of it. In spite of various correctness proofs, the logical machinery relating the proof-theoretic speciication of a logic programming language and its compiled form is still poorly understood. In this paper, we propose a logic-independent deenition of ...
متن کاملDenotational Style Correctness of a CPS-Transform Based Compiler
Correctness is a crucial property for compilers; programmersrely on it when writing code. Ideally, correctness should beproved. Work on compiler correctness has focused on directtranslation strategies. However, in practice, the continua-tion passing style (CPS) transform (or a variant) is oftenused in the translation process. Here a simple source lan-guage and its CPS-tr...
متن کاملIntegrating an Equality Prover into a Software Development System Based on Type Theory
This paper reports on the integration of an untyped equational prover into a proof system based on an expressive constructive type theory. The proofs returned by the equational prover are eeectively veriied for type correctness, a proof term can be constructed. The scheme of proof translation described here is illustrated by the integration of the Discount prover into the software development s...
متن کاملTowards Proof Generating Compilers
Correctness of compilation is important for the reliability of software. New techniques to guarantee correctness do not verify the compiler itself, but check for each compiled program whether it is correctly translated. Following these ideas, we developed an approach in which checking is realized as proof checking within a formal specification and verification framework. Based on formal specifi...
متن کامل