Skip to main content

Type-checking Revisited: Modular Error-handling

  • Conference paper
Semantics of Specification Languages (SoSL)

Part of the book series: Workshops in Computing ((WORKSHOPS COMP.))

Abstract

Static-semantics determines the validity of a program, while a type-checker provides more specific type error information. Type-checkers are specified based on the static semantics specification, for the purpose of identifying and presenting type errors in invalid programs.

We discuss a style of algebraically specifying the static semantics of a language which facilitates automatic generation of a type-checker and a language specific error reporter. Such a specification can also be extended in a modular manner to yield human-readable error messages.

Supported by the European Communities, Esprit project 5399: Compiler Generation for Parallel Machines — Compare

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. J.A. Bergstra, J. Heering, and P. Klint, editors. Algebraic Specification. ACM Press Frontier Series. The ACM Press in co-operation with Addison-Wesley, 1989.

    MATH  Google Scholar 

  2. A. van Deursen. An algebraic specification for the static semantics of Pascal. Report CS-R9129, Centrum voor Wiskunde en Informatica (CWI), Amsterdam, 1991. Extended abstract in: Conference Proceedings of Computing Science in the Netherlands CSN’91, pages 150–164. Available by ftp from http://ftp.cwi.nl:/pub/gipe as Deu9l.ps.Z.

  3. A. van Deursen. Origin tracking in primitive recursive schemes. Technical report, Centrum voor Wiskunde en Informatica (CWI), 1993. To appear.

    Google Scholar 

  4. A. van Deursen and T. B. Dinesh. Origin-tracking for higher-order term rewriting systems. In An International Workshop on Higher-Order Algebra, Logic and Term Rewriting, 1993.

    Google Scholar 

  5. A. van Deursen, P. Klint, and F. Tip. Origin tracking. Journal of Symbolic Computation,15:523–545, 1993. Special Issue on Automatic Programming.

    Google Scholar 

  6. T. B. Dinesh. Interactive specification of static semantics from dynamic semantics. Technical report, Centrum voor Wiskunde en Informatica (CWI), 1994. To Appear.

    Google Scholar 

  7. T.B. Dinesh and F. Tip. Animators and error reporters for generated programming environments. Report CS-R9253, Centrum voor Wiskunde en Informatica (CWI), Amsterdam, 1992. Available by ftp from http://ftp.cwi.nl:/pub/gipe as DT92.ps.Z.

  8. J. Goguen, C. Kirchner, H. Kirchner, A. Mégrelis, J. Meseguer, and T. Winkler. An introduction to OBJ3. In S. Kaplan and J.-P. Jouannaud, editors, Proceedings of the First International Workshop on Conditional Term Rewriting Systems, volume 308 of Lecture Notes in Computer Science, pages 258–263. Springer-Verlag, 1988.

    Google Scholar 

  9. J. A. Goguen. Abstract errors for abstract data types. In E.J. Neuhold, editor, Formal descriptions of programming concepts, pages 491–525. North-Holland, 1978.

    Google Scholar 

  10. J. Heering. Second-order algebraic specification of static semantics. Report CS-R9254, Centrum voor Wiskunde en Informatica (CWI), Amsterdam, 1992. Available by ftp from http://ftp.cwi.nl:/pub/gipe as Hee92b.ps.Z.

  11. J. Heering, P.R.H. Hendriks, P. Klint, and J. Rekers. The syntax definition formalism SDF–reference manual. SIGPLAN Notices, 24 (11): 43–75, 1989.

    Article  Google Scholar 

  12. P. Klint. Error handling in algebraic specifications. Unpublished, April 1991.

    Google Scholar 

  13. P. Klint. A meta-environment for generating programming environments. ACM Transactions on Software Engineering Methodology, 2 (2): 176–201, 1993.

    Article  Google Scholar 

  14. P. Naur. Checking of operand types in algol compilers. BIT, 5: 151–163, 1965.

    Article  Google Scholar 

  15. R. Stallman. GNU Emacs Manual. Free Software Foundation, 675 Mass Ave., Cambridge, MA, USA, emacs version 18 edition, 1991. For unix users.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 1994 British Computer Society

About this paper

Cite this paper

Dinesh, T.B. (1994). Type-checking Revisited: Modular Error-handling. In: Andrews, D.J., Groote, J.F., Middelburg, C.A. (eds) Semantics of Specification Languages (SoSL). Workshops in Computing. Springer, London. https://doi.org/10.1007/978-1-4471-3229-5_12

Download citation

  • DOI: https://doi.org/10.1007/978-1-4471-3229-5_12

  • Publisher Name: Springer, London

  • Print ISBN: 978-3-540-19854-3

  • Online ISBN: 978-1-4471-3229-5

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics