Skip to main content

Typing Legacy COBOL Code

  • Conference paper
  • 532 Accesses

Part of the book series: Communications in Computer and Information Science ((CCIS,volume 303))

Abstract

Maintenance of COBOL applications that still exist and work today is an open issue for many companies that have not yet undertaken the crucial decision of migrating to a modern development platform. And even those who did, most likely had to face a major challenge: understanding what those million lines of code do and what business processes they originally implemented. Automating the task of reconstructing the business logic of programs somehow is hard nonetheless: COBOL code is difficult to even get parsed - let alone applying Program Understanding techniques based on sophisticate deductions over information inferred from the code. Here we propose a system based on the translation of COBOL into a simpler and cleaner language and a type system capable of inferring types of program variables. Being COBOL a language in which variable reuse has been a widespread practice for decades, strong typing rules in the usual sense wouldn’t simply fit, therefore our system provides special flow types for tracking multiple types a variable may assume and follows the program control-flow until no more type-changes occur for variables in the typing context. Alongside it detects also a number of error-prone situations, type mismatches and data corruptions due to misalignment or misfit in variable reuse when types have incompatible in-memory representations, while still guaranteing the typing process does not halt.

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

Buying options

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

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Damas, L., Milner, R.: Principal type-schemes for functional programs. In: POPL, pp. 207–212 (1982)

    Google Scholar 

  2. van Deursen, A., Moonen, L.: Type inference for cobol systems. In: WCRE (Working Conference on Reverse Engeneering), pp. 220–230 (1998)

    Google Scholar 

  3. van Deursen, A., Moonen, L.: Understanding cobol systems using inferred types. In: IWPC. IEEE Computer Society (1999)

    Google Scholar 

  4. van Deursen, A., Moonen, L.: Exploring legacy systems using types. In: WCRE (Working Conference on Reverse Engeneering), pp. 32–41 (2000)

    Google Scholar 

  5. van Deursen, A., Moonen, L.: An empirical study into cobol type inferencing. Sci. Comput. Program. 40(2-3), 189–211 (2001)

    Article  MATH  Google Scholar 

  6. Nielson, F., Nielson, H.R., Hankin, C.: Principles of Static Analysis. Springer (1999)

    Google Scholar 

  7. Holt, R.C.: WCRE 1998 most influential paper: Grokking software architecture. In: WCRE (Working Conference on Reverse Engeneering), pp. 5–14. IEEE (2008)

    Google Scholar 

  8. IBM: Cobol z/OS language reference (2009), http://publib.boulder.ibm.com/info-center/pdthelp/v1r1/index.jsp?topic=/com.ibm.debugtool.doc_7.1/eqa7rm0293.html

  9. Kernighan, B.W., Ritchie, D.: The C Programming Language, 2nd edn. Prentice-Hall (1988)

    Google Scholar 

  10. Kuipers, T., Moonen, L.: Types and concept analysis for legacy systems. In: IWPC, pp. 221–230. IEEE Computer Society (2000)

    Google Scholar 

  11. Moonen, L.: Generating robust parsers using island grammars. In: WCRE (Working Conference on Reverse Engeneering) (2001)

    Google Scholar 

  12. Moonen, L.: Exploring software systems. In: ICSM, pp. 276–280. IEEE Computer Society (2003)

    Google Scholar 

  13. Spanò, A., Bugliesi, M., Cortesi, A.: Type-flow analysis for legacy cobol code. In: ICSOFT (2), pp. 64–75 (2011)

    Google Scholar 

  14. Stroustrup, B.: The C++ Programming Language, 3rd edn. Addison-Wesley Longman Publishing Co., Inc., Boston (2000)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2013 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Spanò, A., Bugliesi, M., Cortesi, A. (2013). Typing Legacy COBOL Code. In: Escalona, M.J., Cordeiro, J., Shishkov, B. (eds) Software and Data Technologies. ICSOFT 2011. Communications in Computer and Information Science, vol 303. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-36177-7_10

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-36177-7_10

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-36176-0

  • Online ISBN: 978-3-642-36177-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics