From Contracts Towards Dependent Types: Proofs by Partial Evaluation

  • Stephan Herhut
  • Sven-Bodo Scholz
  • Robert Bernecky
  • Clemens Grelck
  • Kai Trojahner
Part of the Lecture Notes in Computer Science book series (LNCS, volume 5083)

Abstract

The specification and resolution of non-trivial domain constraints has become a well-recognised measure for improving the stability of large software systems. In this paper we propose an approach based on partial evaluation which tries to prove such constraints statically as far as possible and inserts efficient dynamic checks otherwise.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    International Standards Organization: Programming Language APL, Extended. ISO N93.03, ISO (1993)Google Scholar
  2. 2.
    Iverson, K.E.: J Introduction and Dictionary. In: J release. 3rd edn. (1996)Google Scholar
  3. 3.
    Scholz, S.B.: Single Assignment C — efficient support for high-level array operations in a functional setting. Journal of Functional Programming 13(6), 1005–1059 (2003)MATHCrossRefMathSciNetGoogle Scholar
  4. 4.
    Bernecky, R.: Reducing computational complexity with array predicates. In: APL 1998: Proceedings of the APL98 conference on Array processing language, pp. 39–43. ACM Press, New York (1998)CrossRefGoogle Scholar
  5. 5.
    Zenger, C.: Indexed types. Theoretical Computer Science 187(1-2), 147–165 (1997)MATHCrossRefMathSciNetGoogle Scholar
  6. 6.
    Xi, H., Pfenning, F.: Dependent Types in Practical Programming. In: POPL 1999, pp. 214–227. ACM Press, New York (1999)CrossRefGoogle Scholar
  7. 7.
    Chamberlain, B., Choi, S.E., Lewis, E., Lin, C., Snyder, L., Weathersby, W.: ZPL: A Machine Independent Programming Language for Parallel Computers. IEEE Transactions on Software Engineering 26(3), 197–211 (2000)CrossRefGoogle Scholar
  8. 8.
    Chamberlain, B.L., Callahan, D., Zima, H.P.: Parallel programmability and the chapel language. International Journal of High Performance Computing Applications, 291–312 (2007)Google Scholar
  9. 9.
    Meyer, B.: Eiffel: The Language. Prentice Hall, Englewood Cliffs (1990)Google Scholar
  10. 10.
    Meyer, B.: Applying design by contract. Computer 25(10), 40–51 (1992)CrossRefGoogle Scholar
  11. 11.
    Kramer, R.: iContract - The Java(tm) design by contract(tm) tool. In: TOOLS 1998, p. 295. IEEE Computer Society, Los Alamitos (1998)Google Scholar
  12. 12.
    Karaorman, M., Holzle, U., Bruno, J.: jContractor: A reflective java library to support design by contract. In: Proceedings Reflection 1999, The Second International Conference on Meta-Level Architectures and Reflection, Santa Barbara, CA, USA, pp. 19–21. University of California at Santa Barbara (1999)Google Scholar
  13. 13.
    Ploesch, R.: Design by contract for python. In: APSEC 1997: Proceedings of the Fourth Asia-Pacific Software Engineering and International Computer Science Conference, Washington, DC, USA, p. 213. IEEE Computer Society, Los Alamitos (1997)CrossRefGoogle Scholar
  14. 14.
    Pierce, B.C.: Types and programming languages. MIT Press, Cambridge (2002)Google Scholar
  15. 15.
    Trojahner, K., Grelck, C., Scholz, S.B.: On Optimising Shape-Generic Array Programs using Symbolic Structural Information. In: Horváth, Z., Zsók, V. (eds.) IFL 2006. LNCS, vol. 4449, pp. 1–18. Springer, Heidelberg (2007)CrossRefGoogle Scholar
  16. 16.
    Bernecky, R.: Shape cliques. ACM SIGAPL Quote Quad 35(3), 7–17 (2007)CrossRefGoogle Scholar
  17. 17.
    McMahon, F.H.: The livermore fortran kernels: A computer test of the numerical performance range. Technical Report UCRL-53745, Lawrence Livermore National Laboratory, Livermore, CA (1986)Google Scholar
  18. 18.
    Cann, D., Feo, J.: SISAL versus FORTRAN: a comparison using the livermore loops. In: Supercomputing 1990: Proceedings of the 1990 ACM/IEEE conference on Supercomputing, Washington, DC, USA, pp. 626–636. IEEE Computer Society, Los Alamitos (1990)Google Scholar
  19. 19.
    Flanagan, C.: Hybrid type checking. In: POPL 2006: Conference record of the 33rd ACM SIGPLAN-SIGACT symposium on Principles of programming languages, pp. 245–256. ACM, New York (2006)CrossRefGoogle Scholar
  20. 20.
    Xu, D.N.: Extended static checking for haskell. In: Haskell 2006: Proceedings of the 2006 ACM SIGPLAN workshop on Haskell, pp. 48–59. ACM, New York (2006)CrossRefGoogle Scholar
  21. 21.
    Menon, V.S., Glew, N., Murphy, B.R., McCreight, A., Shpeisman, T., Adl-Tabatabai, A.R., Petersen, L.: A verifiable ssa program representation for aggressive compiler optimization. In: POPL 2006: Conference record of the 33rd ACM SIGPLAN-SIGACT symposium on Principles of programming languages, Charleston, South Carolina, USA, pp. 397–408. ACM, New York (2006)CrossRefGoogle Scholar
  22. 22.
    McBride, C., McKinna, J.: The view from the left. J. Funct. Program. 14(1), 69–111 (2004)MATHCrossRefMathSciNetGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2008

Authors and Affiliations

  • Stephan Herhut
    • 1
  • Sven-Bodo Scholz
    • 1
  • Robert Bernecky
    • 2
  • Clemens Grelck
    • 1
    • 3
  • Kai Trojahner
    • 3
  1. 1.University of HertfordshireU.K.
  2. 2.University of TorontoCanada
  3. 3.University of LübeckGermany

Personalised recommendations