Type Checking Evolving Languages with MSOS

  • M. G. J. van den Brand
  • A. P. van der Meer
  • A. Serebrenik
Part of the Lecture Notes in Computer Science book series (LNCS, volume 5700)


Evolution of programming languages requires co-evolution of static analysis tools designed for these languages. Traditional approaches to static analysis, e.g., those based on Structural Operational Semantics (SOS), assume, however, that the syntax and the semantics of the programming language under consideration are fixed. Language modification is, therefore, likely to cause redevelopment of the analysis techniques and tools. Moreover, the redevelopment cost can discourage the language engineers from improving the language design.

To address the co-evolution problem we suggest to base static analyses on modular structural operational semantics (MSOS). By using an intrinsically modular formalism, type rules can be added, removed or modified easily. We illustrate our approach by developing an MSOS-based type analysis technique for Chi, a domain specific language for hybrid systems engineering.


Transition Rule Typing Scheme Language Designer Numerical Type Return Type 
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.
    Jürgens, E., Pizka, M.: Tool-supported multi-level language evolution. In: Männistö, T., Niemelä, E., Raatikainen, M. (eds.) Software and Services Variability Management Workshop – Concepts, Models and Tools, vol. (3), pp. 48–67. Helsinki University of Technology Software Business and Engineering Institute Research Reports, Helsinki (2007)Google Scholar
  2. 2.
    Mosses, P.D.: Modular structural operational semantics. Journal of Logic and Algebraic Programming 60-61, 195–228 (2004)MathSciNetCrossRefzbMATHGoogle Scholar
  3. 3.
    Mosses, P.D.: Foundations of modular SOS. In: Kutyłowski, M., Wierzbicki, T., Pacholski, L. (eds.) MFCS 1999. LNCS, vol. 1672, pp. 70–80. Springer, Heidelberg (1999)CrossRefGoogle Scholar
  4. 4.
    Hofkamp, A., Rooda, J.: Chi 1.0 reference manual. SE Report 2008-04, Eindhoven University of Technology, Systems Engineering Group, Department of Mechanical Engineering, Eindhoven, The Netherlands (2008)Google Scholar
  5. 5.
    van Beek, D., Hofkamp, A., Reniers, M., Rooda, J., Schiffelers, R.: Syntax and consistent equation semantics of Chi 2.0. SE Report 2008-01, Eindhoven University of Technology (2008)Google Scholar
  6. 6.
    Alur, R., Courcoubetis, C., Halbwachs, N., Henzinger, T.A., Ho, P., Nicollin, X., Olivero, A., Sifakis, J., Yovine, S.: The algorithmic analysis of hybrid systems. Theoretical Computer Science 138, 3–34 (1995)MathSciNetCrossRefzbMATHGoogle Scholar
  7. 7.
    Bohdziewicz, J., Sroka, E.: Application of hybrid systems to the treatment of meat industry wastewater. Desalination 198(1-3), 33–40 (2006); The Second Membrane Science and Technology Conference of Visegrad CountriesCrossRefGoogle Scholar
  8. 8.
    Clavel, M., Durán, F., Eker, S., Lincoln, P., Martí-Oliet, N., Meseguer, J., Talcott, C.: The Maude 2.0 system. In: Nieuwenhuis, R. (ed.) RTA 2003. LNCS, vol. 2706, pp. 76–87. Springer, Heidelberg (2003)CrossRefGoogle Scholar
  9. 9.
    Plotkin, G.D.: A Structural Approach to Operational Semantics. Technical Report DAIMI FN-19, University of Aarhus (1981)Google Scholar
  10. 10.
    Braga, C., Haeusler, E., Meseguer, J., Mosses, P.D.: Mapping modular SOS to rewriting logic. In: Leuschel, M. (ed.) LOPSTR 2002. LNCS, vol. 2664, pp. 262–277. Springer, Heidelberg (2003)CrossRefGoogle Scholar
  11. 11.
    Braga, C.: Rewriting Logic as a Semantic Framework for Modular Structural Operational Semantics. PhD thesis, Pontifícia Universidade Católica do Rio de Janeiro (2001),
  12. 12.
    Hofkamp, A., Rooda, J.: Chi 2.0 language reference manual. SE Report 2008-02, Eindhoven University of Technology, Systems Engineering Group, Department of Mechanical Engineering, Eindhoven, The Netherlands (2008)Google Scholar
  13. 13.
    Tofte, M.: Operational semantics and polymorphic type inference. PhD thesis, University of Edinburgh (1988)Google Scholar
  14. 14.
    Pierce, B.C.: Types and Programming Languages. MIT Press, Cambridge (2002)zbMATHGoogle Scholar
  15. 15.
    Flanagan, C.: Hybrid type checking. In: Morrisett, J.G., Jones, S.L.P. (eds.) Principles of Programming Languages, pp. 245–256. ACM Press, New York (2006)Google Scholar
  16. 16.
    Mitchell, J.: Coercion and type inference. In: Eleventh Symposium on Principles of Programming Languages, pp. 175–185 (1984)Google Scholar
  17. 17.
    Hoang, M., Mitchell, J.C.: Lower bounds on type inference with subtypes. In: Proceedings of POPL 1995, 22nd Annual SIGPLAN–SIGACT Symposium on Principles of Programming Languages, pp. 176–185 (1995)Google Scholar
  18. 18.
    Frey, A.: Satisfying systems of subtype inequalities in polynomial space. In: Van Hentenryck, P. (ed.) SAS 1997. LNCS, vol. 1302. Springer, Heidelberg (1997)CrossRefGoogle Scholar
  19. 19.
    Meseguer, J., Rosu, G.: Rewriting logic semantics: From language specifications to formal analysis tools. In: Basin, D., Rusinowitch, M. (eds.) IJCAR 2004. LNCS (LNAI), vol. 3097, pp. 1–44. Springer, Heidelberg (2004)CrossRefGoogle Scholar
  20. 20.
    Attali, I.: Compiling TYPOL with attribute grammars. In: Małuszyński, J., Deransart, P., Lorho, B. (eds.) PLILP 1988. LNCS, vol. 348, pp. 252–272. Springer, Heidelberg (1989)CrossRefGoogle Scholar
  21. 21.
    Dijkstra, A., Swierstra, S.D.: Typing haskell with an attribute grammar. In: Vene, V., Uustalu, T. (eds.) AFP 2004. LNCS, vol. 3622, pp. 1–72. Springer, Heidelberg (2005)CrossRefGoogle Scholar
  22. 22.
    Gao, J., Heimdahl, M.P.E., Van Wyk, E.: Flexible and extensible notations for modeling languages. In: Dwyer, M.B., Lopes, A. (eds.) FASE 2007. LNCS, vol. 4422, pp. 102–116. Springer, Heidelberg (2007)CrossRefGoogle Scholar
  23. 23.
    Knuth, D.E.: Semantics of context-free languages. Theory of Computing Systems 2(2), 127–145 (1968)MathSciNetzbMATHGoogle Scholar
  24. 24.
    de Moor, O., Backhouse, K., Swierstra, S.D.: First-class attribute grammars. Informatica (Slovenia) 24(3) (2000)Google Scholar
  25. 25.
    van Deursen, A.: An algebraic specification for the static semantics of Pascal. In: Conference Proceedings Computing Science in the Netherlands CSN 1991, pp. 150–164 (1991)Google Scholar
  26. 26.
    van Deursen, A., Heering, J., Klint, P. (eds.): Language Prototyping: An Algebraic Specification Approach. AMAST Series in Computing, vol. 5. World Scientific, Singapore (1996)zbMATHGoogle Scholar
  27. 27.
    van den Brand, M., van Deursen, A., Heering, J., de Jong, H., de Jonge, M., Kuipers, T., Klint, P., Moonen, L., Olivier, P., Scheerder, J., Vinju, J., Visser, E., Visser, J.: The ASF+SDF Meta-Environment: a Component-Based Language Development Environment. In: Wilhelm, R. (ed.) CC 2001. LNCS, vol. 2027, pp. 365–370. Springer, Heidelberg (2001)CrossRefGoogle Scholar
  28. 28.
    Dinesh, T.B.: Type-checking revisited: Modular error-handling. In: Andrews, D.J., Groote, J.F., Middelburg, C.A. (eds.) Semantics of Specification Languages. Workshops in Computing, pp. 216–231. Springer, Heidelberg (1993)Google Scholar
  29. 29.
    Despeyroux, T.: Executable specification of static semantics. Research Report RR-0295, INRIA (1984)Google Scholar
  30. 30.
    Marcotty, M., Ledgard, H., Bochmann, G.V.: A sampler of formal definitions. ACM Computing Surveys 8(2), 191–276 (1976)CrossRefzbMATHGoogle Scholar
  31. 31.
    Lämmel, R., Wachsmuth, G.: Transformation of SDF syntax definitions in the ASF+SDF meta-environment. In: van den Brand, M.G., Parigot, D. (eds.) Proceedings of the 1st Workshop on Language Descriptions, Tools and Applications. Electronical Notes in Theoretical Computer Science, vol. 44, Elsevier, Amsterdam (2001)Google Scholar
  32. 32.
    Mosses, P.D., New, M.J.: Implicit propagation in structural operational semantics. In: SOS 2008, Preliminary Proceedings (2008)Google Scholar
  33. 33.
    Doh, K.G., Mosses, P.D.: Composing programming languages by combining action-semantics modules. Sci. Comput. Program. 47(1), 3–36 (2003)CrossRefzbMATHGoogle Scholar
  34. 34.
    van den Brand, M.G., Iversen, J., Mosses, P.D.: An action environment. Sci. Comput. Program. 61(3), 245–264 (2006)MathSciNetCrossRefzbMATHGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2009

Authors and Affiliations

  • M. G. J. van den Brand
    • 1
  • A. P. van der Meer
    • 1
  • A. Serebrenik
    • 1
  1. 1.Technische Universiteit EindhovenEindhovenThe Netherlands

Personalised recommendations