Specialization of Functional Logic Programs Based on Needed Narrowing
Maria Alpuente, Michael Hanus, Salvador Lucas, German Vidal

TL;DR
This paper explores partial evaluation in functional logic programs based on needed narrowing, ensuring correctness and preservation of program structure, which supports reliable program specialization.
Contribution
It establishes the correctness of partial evaluation using needed narrowing and demonstrates that program structure is preserved, facilitating reliable specialization.
Findings
Correctness of partial evaluation based on needed narrowing.
Preservation of original program structure after partial evaluation.
Foundation for correctness of partial evaluators in declarative multi-paradigm languages.
Abstract
Many functional logic languages are based on narrowing, a unification-based goal-solving mechanism which subsumes the reduction mechanism of functional languages and the resolution principle of logic languages. Needed narrowing is an optimal evaluation strategy which constitutes the basis of modern (narrowing-based) lazy functional logic languages. In this work, we present the fundamentals of partial evaluation in such languages. We provide correctness results for partial evaluation based on needed narrowing and show that the nice properties of this strategy are essential for the specialization process. In particular, the structure of the original program is preserved by partial evaluation and, thus, the same evaluation strategy can be applied for the execution of specialized programs. This is in contrast to other partial evaluation schemes for lazy functional logic programs which may…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
