Skip to main content

Extensible denotational language specifications

  • Invited Talk 3
  • Conference paper
  • First Online:

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

Abstract

Traditional denotational semantics assigns radically different meanings to one and the same phrase depending on the rest of the programming language. If the language is purely functional, the denotation of a numeral is a function from environments to integers. But, in a functional language with imperative control operators, a numeral denotes a function from environments and continuations to integers. This paper introduces a new format for denotational language specifications, extended direct semantics, that accommodates orthogonal extensions of a language without changing the denotations of existing phrases. An extended direct semantics always maps a numeral to the same denotation: the injection of the corresponding number into the domain of values. In general, the denotation of a phrase in a functional language is always a projection of the denotation of the same phrase in the semantics of an extended language—no matter what the extension is. Based on extended direct semantics, it is also possible to construct interpreters for complete languages by composing interpreters for language fragments.

The paper is an extended and revised version of Rice Technical Report 90-105, “Extended Direct Semantics”, January 1990.

The authors are partially supported by NSF grant CCR 91-22518. The second author is also partially supported by Arpa grant 8313, issued by ESD/AVS under Contract No. F196228-91-C-0168 under the direction of Robert Harper and Peter Lee.

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

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Allison, L.A Practical Introduction to Denotational Semantics. Cambridge Computer Science Texts 23. Cambridge University Press, Cambridge, England. 1986.

    Google Scholar 

  2. Allison, L. Direct semantics and exceptions define jumps and coroutines. Information Processing Letters31, 1989, 327–330.

    Google Scholar 

  3. Bjørner, D. and C. Jones. Formal Specification and Software Development. Prentice Hall International, 1982.

    Google Scholar 

  4. Blikle, A. and A. Tarlecki. Naive denotational semantics. In Proc. IFIP 9th World Computer Congress: Information Processing 83, North-Holland, Amsterdam, 1983, 345–355.

    Google Scholar 

  5. Crank, E. and M. Felleisen. Parameter-passing and the lambdacalculus. In Proc. 18th ACM Symposium on Principles of Programming Languages, 1991, 233–245.

    Google Scholar 

  6. Demichiel, L.G. Overview: The Common Lisp Object System. Lisp and Symbolic Computation1(3/4), 1988, 227–244.

    Google Scholar 

  7. Dybvig, R. K.The Scheme Programming Language, Prentice-Hall, Englewood Cliffs, New Jersey, 1987.

    Google Scholar 

  8. Dybvig, R. K. and R. Hieb. Engines from continuations. Journal of Computer Languages (Pergamon Press) 14(2), 1989, 109–124.

    Google Scholar 

  9. Felleisen, M. and D.P. Friedman. A reduction semantics for imperative higher-order languages. In Proc. Conference on Parallel Architectures and Languages Europe, Volume II: Parallel Languages. Lecture Notes in Computer Science 259. Springer-Verlag, Heidelberg, 1987, 206–223.

    Google Scholar 

  10. Felleisen, M. and D.P. Friedman. A syntactic theory of sequential state. Theor. Comput. Sci.69(3), 1989, 243–287. Preliminary version in: Proc. 14th ACM Symposium on Principles of Programming Languages, 1987, 314–325.

    Google Scholar 

  11. Felleisen, M. and R. Hieb. The revised report on the syntactic theories of sequential control and state. Technical Report 100, Rice University, June 1989. Theor. Comput. Sci.102, 1992, 235–271.

    Google Scholar 

  12. Felleisen, M., D.P. Friedman, E. Kohlbecker, and B. Duba. A syntactic theory of sequential control. Theor. Comput. Sci.52(3), 1987, 205–237. Preliminary version in: Proc. Symposium on Logic in Computer Science, 1986, 131–141.

    Google Scholar 

  13. Filinski, A. Representing monads. In Proc. 21st ACM Symposium on Principles of Programming Languages, 1994, to appear.

    Google Scholar 

  14. Friedman, D.P., C.T. Haynes, and E. Kohlbecker. Programming with continuations. In Program Transformations and Programming Environments, edited by P. Pepper. Springer-Verlag, Heidelberg, 1985, 263–274.

    Google Scholar 

  15. Gordon, M.J.The Denotational Description of Programming Languages, Springer-Verlag, New York, 1979.

    Google Scholar 

  16. Haynes, C.T., D.P. Friedman, and M. Wand. Obtaining coroutines from continuations. Journal of Computer Languages (Pergamon Press) 11, 1986, 143–153. Preliminary Version in Lisp and Functional Programming, 1984, Austin, TX.

    Google Scholar 

  17. Kanneganti, R., and R. Cartwright. What is a universal higher-order programming language? In Proc. International Conference on Automata, Languages, and Programming. Lecture Notes in Computer Science 700. Springer Verlag, Berlin, 1993, 682–695.

    Google Scholar 

  18. Meyer, A.R. and M. Wand. Continuation semantics in typed lambdacalculi. Proc. Workshop Logics of Programs, Lecture Notes in Computer Science 193, Springer-Verlag, Heidelberg, 1985, 219–224.

    Google Scholar 

  19. Milner, R., M. Tofte, and R. Harper. The Definition of Standard ML. The MIT Press, Cambridge, Massachusetts and London, England, 1990.

    Google Scholar 

  20. Moggi, E. An abstract view of programming languages. LFCS Report ECS-LFCS-90-113, University of Edinburgh, 1990.

    Google Scholar 

  21. Moggi, E. Notions of computations and monads. Inf. and Comp.93, 1991, 55–92.

    Google Scholar 

  22. Moggi, E. Computational lambda-calculus and monads. In Proc. Fourth Symposium on Logic in Computer Science, 1989, 14–23.

    Google Scholar 

  23. Mosses, P. Denotational Semantics. In Handbook of Theoretical Computer Science, North-Holland, Amsterdam, 1991, 575–631.

    Google Scholar 

  24. Plotkin, G.Tω as a Universal Domain. J. Comput. Syst. Sci.17, 1978, 209–236.

    Google Scholar 

  25. Rees, J. and W. Clinger (Eds.). The revised3 report on the algorithmic language Scheme. SIGPLAN Notices 21(12), 1986, 37–79.

    Google Scholar 

  26. Reynolds, J.C. On the relation between direct and continuation semantics. In Proc. International Conference on Automata, Languages and Programming, 1974, 141–156.

    Google Scholar 

  27. Schmidt, D.A.Denotational Semantics: A Methodology for Language Development. Allyn and Bacon, Newton, Mass., 1986.

    Google Scholar 

  28. Scott, D. S. Domains for denotational semantics. In Proc. International Conference on Automata, Languages, and Programming, Lecture Notes in Mathematics 140, Springer Verlag, Berlin, 1982, 577–613.

    Google Scholar 

  29. Scott, D.S. Data types as lattices. SIAM J. Comput.5(3), 1976, 522–587.

    Google Scholar 

  30. Sethi R. and A. Tang. Constructing call-by-value continuation semantics. J. ACM27(3), 1980, 580–597.

    Google Scholar 

  31. Sitaram, D. and M. Felleisen. Modeling continuations without continuations. In Proc. 18th ACM Symposium on Principles of Programming Languages, 1991, 185–196.

    Google Scholar 

  32. Steele, G.L., Jr.Common Lisp—The Language. Digital Press, 1984.

    Google Scholar 

  33. Steele, G.L., Jr. Building interpreters by composing monads. In Proc. 21st ACM Symposium on Principles of Programming Languages, 1994, to appear.

    Google Scholar 

  34. Stoy, J. The congruence of two programming language definitions. Theor. Comput. Sci.13, 1981, 151–174.

    Google Scholar 

  35. Stoy, J.E.Denotational Semantics: The Scott-Strachey Approach to Programming Languages. The MIT Press, Cambridge, Mass. 1981.

    Google Scholar 

  36. Strachey, C. and C.P. Wadsworth. Continuations: A mathematical semantics for handling full jumps. Technical Monograph PRG-11, Oxford University Computing Laboratory, Programming Research Group, 1974.

    Google Scholar 

  37. Sussman, G.J. and G.L. Steele Jr. Scheme: An interpreter for extended lambda calculus. Memo 349, MIT AI Lab, 1975.

    Google Scholar 

  38. Wadler, P. The essence of functional programming. In Proc. 19th ACM Symposium on Principles of Programming Languages, 1992, 1–14.

    Google Scholar 

  39. Wand, M. Continuation-based multiprocessing. In Proc. 1980 ACM Conference on Lisp and Functional Programming, 1980, 19–28.

    Google Scholar 

  40. Wright, A. and M. Felleisen. A syntactic approach to type soundness. Technical Report 160. Rice University, 1991. Information and Computation, 1993, to appear.

    Google Scholar 

  41. Wright, A.K. and R. Cartwright. A practical soft type system for Scheme. Technical Report Rice CS 93-218. Rice University, December 1993.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Masami Hagiya John C. Mitchell

Rights and permissions

Reprints and permissions

Copyright information

© 1994 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Cartwright, R., Felleisen, M. (1994). Extensible denotational language specifications. In: Hagiya, M., Mitchell, J.C. (eds) Theoretical Aspects of Computer Software. TACS 1994. Lecture Notes in Computer Science, vol 789. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-57887-0_99

Download citation

  • DOI: https://doi.org/10.1007/3-540-57887-0_99

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-57887-1

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

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics