Distributed Programming in a Multi-Paradigm Declarative Language

  • Michael Hanus
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 1702)


Curry is a multi-paradigm declarative language covering functional, logic, and concurrent programming paradigms. Curry’s operational semantics is based on lazy reduction of expressions extended by a possibly non-deterministic binding of free variables occurring in expressions. Moreover, constraints can be executed concurrently which provides for concurrent computation threads that are synchronized on logical variables. In this paper, we extend Curry’s basic computational model by a few primitives to support distributed applications where a dynamically changing number of different program units must be coordinated. We develop these primitives as a special case of the existing basic model so that the new primitives interact smoothly with the existing features for search and concurrent computations. Moreover, programs with local concurrency can be easily transformed into distributed applications. This supports a simple development of distributed systems that are executable on local networks as well as on the Internet. In particular, sending partially instantiated messages containing logical variables is quite useful to implement reply messages. We demonstrate the power of these primitives by various programming examples.


Logic Program Logic Programming Free Variable Logical Variable Incoming Message 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.


  1. 1.
    Antoy, S., Echahed, R., Hanus, M.: A Needed Narrowing Strategy. In: Proc. 21st ACM Symp. on Principles of Programming Languages, pp. 268–279 (1994)Google Scholar
  2. 2.
    Armstrong, J., Williams, M., Wikstrom, C., Virding, R.: Concurrent Programming in Erlang. Prentice Hall, Englewood Cliffs (1996)Google Scholar
  3. 3.
    Breitinger, S., Loogen, R., Ortega-Mallen, Y.: Concurrency in Functional and Logic Programming. In: Fuji International Workshop on Functional and Logic Programming. World Scientific Publ., Singapore (1995)Google Scholar
  4. 4.
    Chakravarty, M.M.T., Guo, Y., Köhler, M.: Distributed Haskell: Goffin on the Internet. In: Proc. of the Third Fuji International Symposium on Functional and Logic Programming, World Scientific. Singapore (1998)Google Scholar
  5. 5.
    Giovannetti, E., Levi, G., Moiso, C., Palamidessi, C.: Kernel LEAF: A Logic plus Functional Language. Journal of Computer and System Sciences 42(2), 139–185 (1991)zbMATHCrossRefGoogle Scholar
  6. 6.
    González-Moreno, J.C., Hortalá-González, M.T., Rodríguez-Artalejo, M.: A Higher Order Rewriting Logic for Functional Logic Programming. In: Proc. Int. Conference on Logic Programming (ICLP 1997), pp. 153–167. MIT Press, Cambridge (1997)Google Scholar
  7. 7.
    Hanus, M.: The Integration of Functions into Logic Programming: From Theory to Practice. Journal of Logic Programming 19,20, 583–628 (1994)CrossRefMathSciNetGoogle Scholar
  8. 8.
    Hanus, M.: Analysis of Residuating Logic Programs. Journal of Logic Programming 24(3), 161–199 (1995)CrossRefMathSciNetGoogle Scholar
  9. 9.
    Hanus, M.: A Unified Computation Model for Functional and Logic Programming. In: Proc. 24th ACM Symp. Principles of Programming Languages, pp. 80–93 (1997)Google Scholar
  10. 10.
    Hanus, M., Réty, P.: Demand-driven Search in Functional Logic Programs. Research Report RR-LIFO-98-08, Univ. Orléans (1998)Google Scholar
  11. 11.
    Hanus, M., Sadre, R.: An Abstract Machine for Curry and its Concurrent Implementation in Java. Journal of Functional and Logic Programming (6) (1999)Google Scholar
  12. 12.
    Hanus, M., Steiner, F.: Controlling Search in Declarative Programs. In: Palamidessi, C., Meinke, K., Glaser, H. (eds.) ALP 1998 and PLILP 1998. LNCS, vol. 1490, pp. 374–390. Springer, Heidelberg (1998)CrossRefGoogle Scholar
  13. 13.
    Hanus, M. (ed.): Curry: An Integrated Functional Logic Language, Vers. 0.5 (1999), Available at
  14. 14.
    Hughes, J.: Why Functional Programming Matters. In: Turner, D.A. (ed.) Research Topics in Functional Programming, pp. 17–42. Addison Wesley, Reading (1990)Google Scholar
  15. 15.
    Janson, S., Haridi, S.: Programming Paradigms of the Andorra Kernel Language. In: Proc. 1991 Int. Logic Programming Symposium, pp. 167–183. MIT Press, Cambridge (1991)Google Scholar
  16. 16.
    Janson, S., Montelius, J., Haridi, S.: Ports for Objects in Concurrent Logic Programs. In: Research Directions in Concurrent Object-Oriented Programming. MIT Press, Cambridge (1993)Google Scholar
  17. 17.
    Liskov, B., Shrira, L.: Promises: Linguistic Support for Efficient Asynchronous Procedure Calls in Distributed Systems. In: Proc. SIGPLAN 1988 Conference on Programming Language Design and Implementation, pp. 260–267 (1988)Google Scholar
  18. 18.
    Milner, R., Parrow, J., Walker, D.: A calculus of mobile processes, Parts I and II. Information and Computation 100, 1–77 (1992)zbMATHCrossRefMathSciNetGoogle Scholar
  19. 19.
    Moreno-Navarro, J.J., Rodríguez-Artalejo, M.: Logic Programming with Functions and Predicates: The Language BABEL. Journal of Logic Programming 12, 191–223 (1992)zbMATHCrossRefGoogle Scholar
  20. 20.
    Peterson, J., et al.: Haskell: A Non-strict, Purely Functional Language (Version 1.4). Technical Report, Yale University (1997)Google Scholar
  21. 21.
    Peyton Jones, S.L., Gordon, A., Finne, S.: Concurrent Haskell. In: Proc. 23rd ACM Symp. on Principles of Programming Languages, pp. 295–308 (1996)Google Scholar
  22. 22.
    Saraswat, V.A.: Concurrent Constraint Programming. MIT Press, Cambridge (1993)Google Scholar
  23. 23.
    Shapiro, E.: The family of concurrent logic programming languages. ACM Computing Surveys 21(3), 412–510 (1989)CrossRefGoogle Scholar
  24. 24.
    Shapiro, E., Takeuchi, A.: Object Oriented Programming in Concurrent Prolog. In: Concurrent Prolog: Collected Papers, vol. 2, pp. 251–273. MIT Press, Cambridge (1987)Google Scholar
  25. 25.
    Smolka, G.: The Oz Programming Model. In: van Leeuwen, J. (ed.) Computer Science Today. LNCS, vol. 1000, pp. 325–343. Springer, Heidelberg (1995)CrossRefGoogle Scholar
  26. 26.
    Van Roy, P., Haridi, S., Brand, P., Smolka, G., Mehl, M., Scheidhauer, R.: Mobile Objects in Distributed Oz. ACM TOPLAS 19(5), 804–851 (1997)CrossRefGoogle Scholar
  27. 27.
    Wadler, P.: How to Declare an Imperative. In: Proc. of the 1995 International Logic Programming Symposium, pp. 18–32. MIT Press, Cambridge (1995)Google Scholar
  28. 28.
    Warren, D.H.D.: Higher-order extensions to PROLOG: are they needed? Machine Intelligence 10, 441–454 (1982)Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 1999

Authors and Affiliations

  • Michael Hanus
    • 1
  1. 1.Informatik IIRWTH AachenAachenGermany

Personalised recommendations