Skip to main content

Theoretical Foundations for the Declarative Debugging of Lazy Functional Logic Programs

  • Conference paper
  • First Online:
Functional and Logic Programming (FLOPS 2001)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2024))

Included in the following conference series:

Abstract

The aim of this paper is to provide theoretical foundations for the declarative debugging of wrong answers in lazy functional logic programming. We rely on a logical framework which formalizes both the intended meaning and the execution model of programs in a simple language which combines the expressivity of pure Prolog and a significant subset of Haskell. As novelties w.r.t. to previous related approaches, we deal with functional values both as arguments and as results of higher order functions, we obtain a completely formal specification of the debugging method, and we extend known soundness and completeness results for the debugging of wrong answers in logic programming to a substantially more difficult context. A prototype implementation of a working debugger is planned as future work.

Work partially supported by the Spanish CICYT (project CICYT-TIC98-0445-C03-02/97 ‘TREND’)

Acknowledgement

We are grateful to the anonymous referees for their constructive remarks.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. S. Antoy, R. Echahed, M. Hanus. A Needed Narrowing Strategy. 21st ACM Symp. on Principles of Programming Languages, Portland, ACM Press, pp. 268–279, 1994.

    Google Scholar 

  2. G. Ferrand. Error Diagnosis in Logic Programming, an Adaptation of E.Y. Shapiro’s Method. The Journal of Logic Programming 4(3), pp. 177–198, 1987.

    Article  MathSciNet  Google Scholar 

  3. M. Falaschi, G. Levi, M. Martelli, C. Palamidessi. A Model-theoretic Reconstruction of the Operational Semantics of Logic Programs. Information and Computation 102(1). pp. 86–113, 1993.

    Article  MathSciNet  Google Scholar 

  4. J.C. González-Moreno, M.T. Hortalá-González, M. Rodrìguez-Artalejo. A Higher Order Rewriting Logic for Functional Logic Programming. Procs. of ICLP’97, The MIT Press, pp. 153–167, 1997.

    Google Scholar 

  5. J.C. González-Moreno, M.T. Hortalá-González, F.J. López-Fraguas, M. Rodrìguez-Artalejo. An Approach to Declarative Programming Based on a Rewriting Logic, Journal of Logic Programming 40(1), pp. 47–87, 1999.

    Article  MathSciNet  Google Scholar 

  6. M. Hanus. The Integration of Functions into Logic Programming: A Survey. J. of Logic Programming 19-20, special issue ‘Ten Years of Logic Programming’, pp. 583–628, 1994.

    Article  Google Scholar 

  7. M. Hanus (ed.), Curry: an Integrated Functional Logic Language, Version 0.7, February 2, 2000. Available at http://www.informatik.uni-kiel.de/~curry/.

  8. J. W. Lloyd. Declarative Error Diagnosis. New Generation Computing 5(2), pp. 133–154, 1987.

    Article  Google Scholar 

  9. R. Loogen, F.J. López-Fraguas, M. Rodrìguez-Artalejo. A Demand Driven Computation Strategy for Lazy Narrowing. Procs. of PLILP’93, Springer LNCS 714, pp. 184-200, 1993.

    Google Scholar 

  10. F.J. López-Fraguas, J. Sánchez-Hernández.T OY: A Multiparadigm Declarative System, in Proc. RTA’99, Springer LNCS 1631, pp 244–247, 1999. Available at http://titan.sip.ucm.es/toy.

    Google Scholar 

  11. L. Naish. Declarative dDebugging of Lazy Functional Programs. Australian Computer Science Communications, 15(1), pp. 287–294, 1993.

    Google Scholar 

  12. L. Naish. A Declarative Debugging Scheme. J. of Functional and Logic Programming, 1997-3.

    Google Scholar 

  13. L. Naish, T. Barbour. A Declarative Debugger for a Logical-Functional Language. In Graham Forsyth and Moonis Ali, eds. Eight International Conference on Industrial and Engineering Applications of Artificial Intelligence and Expert Systems Invited and additional papers, Vol. 2, pp. 91–99, 1995. DSTO General Document 51.

    Google Scholar 

  14. L. Naish, T. Barbour. Towards a Portable Lazy Functional Declarative Debugger. Australian Computer Science Communications, 18(1), pp. 401–408, 1996.

    Google Scholar 

  15. H. Nilsson, P. Fritzson. Algorithmic Debugging of Lazy Funcional Languages. The Journal of Functional Programming, 4(3), pp. 337–370, 1994.

    Google Scholar 

  16. H. Nilsson, J. Sparud. The Evaluation Dependence Tree as a Basis for Lazy Functional Debugging. Automated Software Engineering, 4(2), pp. 121–150, 1997.

    Article  Google Scholar 

  17. H. Nilsson. Declarative Debugging for Lazy Functional Languages. Ph.D. Thesis. Dissertation No. 530. Univ. Linkóping, Sweden. 1998.

    Google Scholar 

  18. J. Peterson, K. Hammond (eds.), Report on the Programming Language Haskell 98, A Non-strict, Purely Functional Language, 1 February 1999.

    Google Scholar 

  19. E.Y. Shapiro. Algorithmic Program Debugging. The MIT Press, Cambridge,Mass., 1982.

    MATH  Google Scholar 

  20. L. Sterling, E. Shapiro. The Art of Prolog. The MIT Press, 1986.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2001 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Caballero, R., López-Fraguas, F.J., Rodrìguez-Artalejo, M. (2001). Theoretical Foundations for the Declarative Debugging of Lazy Functional Logic Programs. In: Kuchen, H., Ueda, K. (eds) Functional and Logic Programming. FLOPS 2001. Lecture Notes in Computer Science, vol 2024. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-44716-4_11

Download citation

  • DOI: https://doi.org/10.1007/3-540-44716-4_11

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-41739-2

  • Online ISBN: 978-3-540-44716-0

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics