skip to main content
10.1145/858570.858571acmconferencesArticle/Chapter ViewAbstractPublication PagesivmeConference Proceedingsconference-collections
Article

Embedding an interpreted language using higher-order functions and types

Published:08 June 2003Publication History

ABSTRACT

Using an embedded, interpreted language to control a complicated application can have significant software-engineering benefits. But existing interpreters are designed for embedding into C code. To embed an interpreter into a different language requires a suitable API. Lua-ML is a new API that uses higher-order functions and types to simplify the use of an embedded interpreter. A typical application-program function can be added to a Lua-ML interpreter simply by describing the function's type.

References

  1. Beazley, David M. 1996. SWIG: An easy to use tool for integrating scripting languages with C and C++. In USENIX, editor, Proceedings of the fourth annual Tcl/Tk Workshop, pages 129--139, Berkeley, CA.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Benson, Brent W. 1994 (October). Libscheme: Scheme as a C library. In Proceedings of the USENIX Symposium on Very High Level Languages, pages 7--19.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Benton, Nick. 2003. Embedded interpreters. See http://research.microsoft.com/~nick.]]Google ScholarGoogle Scholar
  4. Celes, Waldemar. 2003 (March). toLua---accessing C/C++ code from Lua. See http://www.tecgraf.puc-rio.br/~celes/tolua.]]Google ScholarGoogle Scholar
  5. Danvy, Olivier. 1996. Type-directed partial evaluation. In Conference Record of the 23rd Annual ACM Symposium on Principles of Programming Languages, pages 242--257. ACM Press.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. ---. 1998. A simple solution to type specialization. In Proceedings of the 25th International Colloquium on Automata, Languages, and Programming (ICALP), number 1443 in Lecture Notes in Computer Science, pages 908--917. Springer-Verlag.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Ierusalimschy, Roberto, Luiz H. de Figueiredo, and Waldemar Celes. 1996a (June). Lua --- an extensible extension language. Software---Practice & Experience, 26(6):635--652.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. ---. 1996b (November). Reference Manual of the Programming Language Lua 2.5. TeCGraf, PUC-Rio. Available from the author.]]Google ScholarGoogle Scholar
  9. ---. 2001 (May). The evolution of an extension language: A history of Lua. In V Brazilian Symposium on Programming Languages, pages B14--B28. (Invited paper).]]Google ScholarGoogle Scholar
  10. Jenness, Tim and Simon Cozens. 2002 (July). Extending and Embedding Perl. Manning Publications Company.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Laumann, Oliver and Carsten Bormann. 1994 (Fall). Elk: The Extension Language Kit. Computing Systems, 7(4):419--449.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Leroy, Xavier, Damien Doligez, Jacques Garrigue, Didier Rémy, and Jérôme Vouillon. 2001. The Objective Caml system release 3.04: Documentation and user's manual. INRIA. Available at http://pauillac.inria.fr/ocaml/htmlman.]]Google ScholarGoogle Scholar
  13. Ousterhout, John K. 1990 (January). Tcl: An embeddable command language. In Proceedings of the Winter USENIX Conference, pages 133--146.]]Google ScholarGoogle Scholar
  14. ---. 1994. Tcl and the Tk Toolkit. Professional Computing Series. Reading, MA: Addison-Wesley.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Ramsey, Norman. 2003 (March). ML module mania: A typesafe, separately compiled, extensible interpreter. Available from http://www.eecs.harvard.edu/~nr/pubs/mania-abstract.html.]]Google ScholarGoogle Scholar
  16. van Rossum, Guido. 2002. Extending and Embedding the Python Interpreter. Release 2.2.2.]]Google ScholarGoogle Scholar
  1. Embedding an interpreted language using higher-order functions and types

    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
    • Published in

      cover image ACM Conferences
      IVME '03: Proceedings of the 2003 workshop on Interpreters, virtual machines and emulators
      June 2003
      76 pages
      ISBN:1581136552
      DOI:10.1145/858570

      Copyright © 2003 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 8 June 2003

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • Article

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader