Towards a Safe Partial Evaluation of Lazy Functional Logic Programs
Sebastian Fischer, Josep Silva, Salvador Tamarit, Germán Vidal
Abstract
Sebastian Fischer, Josep Silva, Salvador Tamarit, Germán Vidal
Abstract
Partial Evaluation is a well-known technique for specializing programs w.r.t. a given restriction of their input data. Although partial evaluation has been widely investigated in the context of functional and functional logic languages like Haskell or Curry, current schemes are either overly restrictive or destroy sharing through the specialization process, which may produce incorrect specializations when non-deterministic functions are considered. In this work, we present a new partial evaluation scheme for lazy functional logic programs that preserves sharing through the specialization process and still allows the unfolding of arbitrary functions. Furthermore, our approach ensures that sharing is also preserved across non-deterministic computations.
A significance statement is not available in the OpenAlex record.
A contribution statement is not available in the OpenAlex record.
Method details are not available in the OpenAlex metadata.
Findings are not separately available in the OpenAlex metadata.
Limitations are not available in the OpenAlex metadata.
Application details are not available in the OpenAlex metadata.
Partial Evaluation is a well-known technique for specializing programs w.r.t. a given restriction of their input data. Although partial evaluation has been widely investigated in the context of functional and functional logic languages like Haskell or Curry, current schemes are either overly restrictive or destroy sharing through the specialization process, which may produce incorrect specializations when non-deterministic functions are considered. In this work, we present a new partial evaluation scheme for lazy functional logic programs that preserves sharing through the specialization process and still allows the unfolding of arbitrary functions. Furthermore, our approach ensures that sharing is also preserved across non-deterministic computations.
Key concepts: Partial evaluation, Functional programming, Haskell, Computer science, Partial function, Context (archaeology), Lazy evaluation, Programming language