skip to main content
research-article

Exchanging sources between clean and Haskell: a double-edged front end for the clean compiler

Published:30 September 2010Publication History
Skip Abstract Section

Abstract

The functional programming languages Clean and Haskell have been around for over two decades. Over time, both languages have developed a large body of useful libraries and come with interesting language features. It is our primary goal to benefit from each other's evolutionary results by facilitating the exchange of sources between Clean and Haskell and study the forthcoming interactions between their distinct languages features. This is achieved by using the existing Clean compiler as starting point, and implementing a double-edged front end for this compiler: it supports both standard Clean 2.1 and (currently a large part of) standard Haskell 98. Moreover, it allows both languages to seamlessly use many of each other's language features that were alien to each other before. For instance, Haskell can now use uniqueness typing anywhere, and Clean can use newtypes efficiently. This has given birth to two new dialects of Clean and Haskell, dubbed Clean* and Haskell*. Additionally, measurements of the performance of the new compiler indicate that it is on par with the flagship Haskell compiler GHC.

Skip Supplemental Material Section

Supplemental Material

haskell-1120.mov

References

  1. }}Peter Achten. Clean for Haskell 98 programmers - A quick reference guide. http://www.st.cs.ru.nl/papers/2007/achp2007-CleanHaskellQuickGuide.pdf, 2007.Google ScholarGoogle Scholar
  2. }}Peter Achten and Rinus Plasmeijer. The ins and outs of Concurrent Clean I/O. Journal of Functional Programming, 5(1):81--110, 1995.Google ScholarGoogle ScholarCross RefCross Ref
  3. }}Peter Achten, John van Groningen, and Rinus Plasmeijer. High level specification of I/O in functional languages. In John Launchbury and Patrick Sansom, editors, Proceedings of the 5th Glasgow Workshop on Functional Programming, GFP '92, Ayr, UK, Workshops in Computing, pages 1--17. Springer-Verlag, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. }}Artem Alimarine and Rinus Plasmeijer. A generic programming extension for Clean. In Thomas Arts and Markus Mohnen, editors, Selected Papers of the 13th International Workshop on the Implementation of Functional Languages, IFL '01, Stockholm, Sweden, volume 2312 of Lecture Notes in Computer Science, pages 168--186. Springer-Verlag, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. }}Erik Barendsen and Sjaak Smetsers. Conventional and uniqueness typing in graph rewrite systems (extended abstract). In Rudrapatna Shyamasundar, editor, Proceedings of 13th Conference on the Foundations of Software Technology and Theoretical Computer Science, FSTTCS '93, Bombay, India, volume 761 of Lecture Notes in Computer Science, pages 41--51. Springer, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. }}Tom Brus, Marko van Eekelen, Maarten van Leer, and Rinus Plasmeijer. Clean: a language for functional graph rewriting. In Gilles Kahn, editor, Proceedings of the 3rd International Conference on Functional Programming Languages and Computer Architecture, FPCA '87, Portland, OR, USA, pages 364--384, London, UK, 1987. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. }}Manuel Chakravarty. The Haskell 98 Foreign Function Interface 1.0, an addendum to the Haskell 98 report. http://www.cse.unsw.edu.au/~chak/haskell/ffi, 2003.Google ScholarGoogle Scholar
  8. }}Péter Diviánszky. Haskell-Clean compiler. http://aszt.inf.elte.hu/~fun_ver/2003/software/HsCleanAll2.0.2.zip, 2003.Google ScholarGoogle Scholar
  9. }}Marko van Eekelen, Eric Nöcker, Rinus Plasmeijer, and Sjaak Smetsers. Concurrent Clean (version 0.6). Technical Report 90--20, Radboud University Nijmegen, 1990.Google ScholarGoogle Scholar
  10. }}Pieter Hartel. Benchmarking implementations of lazy functional languages II - Two years later. In John Williams, editor, Proceedings of the 6th International Conference on Functional Programming Languages and Computer Architecture, FPCA '93, Copenhagen, Denmark, pages 341--349. ACM Press, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. }}Hajnalka Hegedus. Haskell to Clean front end. Master's thesis, ELTE, Budapest, Hungary, 2001.Google ScholarGoogle Scholar
  12. }}Ralf Hinze. A new approach to generic functional programming. In Tom Reps, editor, Proceedings of the 27th International Symposium on Principles of Programming Languages, POPL '00, Boston, MA, USA, pages 119--132. ACM Press, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. }}Walter de Hoon, Luc Rutten, and Marko van Eekelen. Implementing a functional spreadsheet in CLEAN. Journal of Functional Programming, 5(3):383--414, 1995.Google ScholarGoogle ScholarCross RefCross Ref
  14. }}Paul Hudak, Simon Peyton Jones, Philip Wadler, Brian Boutel, Jon Fairbairn, Joseph Fasel, María Guzmán, Keving Hammond, John Hughes, Thomas Johnsson, Richard Kieburtz, Rishiyur Nikhil, Will Partain, and John Peterson. Report on the programming language Haskell, a nonstrict, purely functional language. ACMSIGPLAN Notices, 27(5):1--164, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. }}Paul Hudak, John Hughes, Simon Peyton Jones, and Philip Wadler. A history of Haskell: being lazy with class. In Barbara Ryder and Brent Hailpern, editors, Proceedings of the 3rd Conference on History of Programming Languages, HOPL III, San Diego, CA, USA, pages 1--55. ACM Press, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. }}Pieter Koopman and Eric Nöcker. Compiling functional languages to term graph rewriting systems. Technical Report 88--1, Radboud University Nijmegen, 1988.Google ScholarGoogle Scholar
  17. }}Pieter Koopman, Marko van Eekelen, and Rinus Plasmeijer. Operational machine specification in a functional programming language. Software: Practice & Experience, 25(5):463--499, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. }}Andres Löh, Dave Clarke, and Johan Jeuring. Dependency-style Generic Haskell. In Colin Runciman and Olin Shivers, editors, Proceedings of the 8th International Conference on Functional Programming, ICFP '03, Uppsala, Sweden, pages 141--152. ACM Press, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. }}Maarten de Mol, Marko van Eekelen, and Rinus Plasmeijer. Theorem proving for functional programmers - Sparkle: a functional theorem prover. In Thomas Arts and Markus Mohnen, editors, Selected Papers of the 13th International Workshop on the Implementation of Functional Languages, IFL '01, Stockholm, Sweden, volume 2312 of Lecture Notes in Computer Science, pages 55--72. Springer-Verlag, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. }}Matthew Naylor. Haskell to Clean translation. Master's thesis, University of York, 2004. http://www-sers.cs.york.ac.uk/~mfn/hacle/hacle.pdf.Google ScholarGoogle Scholar
  21. }}Eric Nöcker. Efficient functional programming - Compilation and programming techniques. PhD thesis, Radboud University Nijmegen, 1994.Google ScholarGoogle Scholar
  22. }}Simon Peyton Jones, editor. Haskell 98 language and libraries: the revised report. Cambridge University Press, 2003.Google ScholarGoogle Scholar
  23. }}Simon Peyton Jones and John Hughes. Report on the programming language Haskell 98. University of Yale, 1999. http://www.haskell.org/definition/.Google ScholarGoogle Scholar
  24. }}Marco Pil. Dynamic types and type dependent functions. In Kevin Hammond, Tony Davie, and Chris Clack, editors, Proceedings of the 10th International Workshop on the Implementation of Functional Languages, IFL '98, London, UK, volume 1595 of Lecture Notes in Computer Science, pages 169--185. Springer-Verlag, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. }}Rinus Plasmeijer and Marko van Eekelen. Functional programming and parallel graph rewriting. Addison-Wesley Publishing Company, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. }}Rinus Plasmeijer and Marko van Eekelen. Clean language report (version 2.1). http://clean.cs.ru.nl, 2002.Google ScholarGoogle Scholar
  27. }}Niklaus Wirth. Programming in MODULA-2 - 3rd, corrected edition. Texts and Monographs in Computer Science. Springer-Verlag, 1985. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Exchanging sources between clean and Haskell: a double-edged front end for the clean compiler

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 45, Issue 11
        HASKELL '10
        November 2010
        156 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/2088456
        Issue’s Table of Contents
        • cover image ACM Conferences
          Haskell '10: Proceedings of the third ACM Haskell symposium on Haskell
          September 2010
          166 pages
          ISBN:9781450302524
          DOI:10.1145/1863523

        Copyright © 2010 ACM

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 30 September 2010

        Check for updates

        Author Tags

        Qualifiers

        • research-article

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!