skip to main content
article
Open Access

A type system equivalent to flow analysis

Authors Info & Claims
Published:01 July 1995Publication History
Skip Abstract Section

Abstract

Flow-based safety analysis of higher-order languages has been studied by Shivers, and Palsberg and Schwartzbach. Open until now is the problem of finding a type system that accepts exactly the same programs as safety analysis. In this article we prove that Amadio and Cardelli's type system with subtyping and recursive types accepts the same programs as a certain safety analysis. The proof involves mappings from types to flow information and back. As a result, we obtain an inference algorithm for the type system, thereby solving an open problem.

References

  1. AMADIO R. M, AND CARDELLI L 1993. Subtypmg recurslve types A CM T~zns. Program. ,Lang. Syst. 15 4 575-63l Also m Proc POPL',Q1 Google ScholarGoogle Scholar
  2. AMTOFT, 7. 1993, Minimal thunkifica~lon. In Procee&ngs of WSA '93. 3rd Inter~natzonal Workshop on Statzc Analyszs. Lecture Notes in Computer Science, vol. 724. SprJnger-Verlag, Berhn, 218-229 Google ScholarGoogle Scholar
  3. BONDORF, A 1991. Automatic autoprolection of higher order recursive equations Sc~. Comput. Progmr. /9, 1-3 (Dec. ~. 3-34 Google ScholarGoogle Scholar
  4. BONDORF, A AND JORGENSEN, J. 1993 Efficient analyses for realistm off-line partJal evaluation, J. Funct. P~'ogra~r,, 5, 3, 315-346.Google ScholarGoogle Scholar
  5. CONSEL C }{993 A ~our of Schism. A partial evMuatmn system for lugher-order applicative languages In Proceaizngs of PEPM'93, 2nd ACM SIGPLAN Symposzum on Partial Google ScholarGoogle Scholar
  6. HEINTZE, N 1994. Set-based aaalysls of ML programs. In Procee, d, mes of the ACM Conference on LISP and Functzonal Progmmrmngo ACM. New York, 306-317. Google ScholarGoogle Scholar
  7. KOZEN~ D., PALSBERG, J., AND SCHWARTZBACH, M. 1. 1994. Efficient inference of partial types .t. Comput. Systo Scz. ~9. 2. 306-324. Also m Proc. FOCS'92, 33rd IEEE Symposium on Foundations of Computer Science, pages 363-37i, Pittsburgh, Pennsylvania, October 1992. Google ScholarGoogle Scholar
  8. KOZEN, D., PALSBERG. J., AND SCHWARTZBACH, M. I. 1995 Effictent recurs~ve subtypmg. In Mathematical Structures ~n Computer Sczence To be published. Also in Proc. POPL'93, 20tb &nnual SIGPLAN-SIGACT Symposmm on Principles of Programming Languages. pages 419-428., Charleston. South Carolina0 January 1993. Google ScholarGoogle Scholar
  9. KUO~ T-}~}{~ AND N~{ISHRA P, 1989 Strmtness analysis: A new perspective based on type reference. In Proceeding~ of the Conference on Ftmctwnal Programming Language~ and Computer Architecture, ACM, New York, 260-272. Google ScholarGoogle Scholar
  10. PALSBERG, J. 1995 Closure analyms ~n constram'c form. A CM Trans. Program. Lanq. Syst. 17, I i3an. I, 47-g2. Google ScholarGoogle Scholar
  11. PALSBERG, J AND SCHWARTZBACH, ~, I 1992. Safety analysts versus type Inference for partlal type9 {n~ P~'oces~'. Letf_ g.~. 175-1~q0. Google ScholarGoogle Scholar
  12. PALSBERG, J AND SCHWAKTZBACH, M, I 1994a Binding-time anaiyms' Abstract interpretation versus type reference. In P~'ocee~zngs of ICCL',9)+. 5th IEEE Internatzonal Conference on Computer Languages IEEE, New York, 289-298.Google ScholarGoogle Scholar
  13. PALSBERG, J. AND SCHWARTZBACH, M I 1994b. Ob~ect-Omented Type Systems. John Wiley & Sons, New York Google ScholarGoogle Scholar
  14. PALSBERG, J. AND SCHWARTZBACH. M I 1995. Safety analysis versus type inference {nil Cornput. 118. 1, 12~-141 Google ScholarGoogle Scholar
  15. SESTOFT, P, 1991. Analysis and efficient implementation of functional programs Ph.D thes~s, DIK{: Un~v of Copenhagen, DenmarkGoogle ScholarGoogle Scholar
  16. SHIVERS. O. 1991a. Control-flow analysm of higher-order languages. Ph.D. thesis, CMU-CS- 91-145, Carnegie Mellon Univ., Pittsburgh, Pa, Google ScholarGoogle Scholar
  17. SHIVERS. O. I991b. Data-flow analysis and type recovery in Scheme. In Topzcs zn Advanced Language Imptementatzon. P Lee~ Ed. MIT Press~ Cambridge, Mass., 47-87.Google ScholarGoogle Scholar
  18. TANG, Y. iVY. AND JOUVELOT~ P. 1994. Separate abstract Jn~erpretatlon for control-flow analysm. In Proceedings ~t" TACS'P,i, Theo~t~ca~, Asvect,~ of Computing Solway, Lecture Notes an Computer Sc~ence~ vol 789. Spriager-Vertago Berlin, 224-243. Google ScholarGoogle Scholar
  19. WAND. M. 1986. Finding the source of type errors. }In she I3th Svmpos~,um or, Pmnczvies of Progrummmg Languages. A CM~ New York, 38-43. Google ScholarGoogle Scholar
  20. WAND. M. 1991. Type inference for record concatenation and multiple inheritance. )nf. Cornput. 98. 1. 1-15 Google ScholarGoogle Scholar
  21. WAND. M AND STECKLER~. P. 1994. Selective and lightweight closure conversion. In Proceedings of POPL '9~, 21st Annual Symposium on Pmnciples of Programmzng Languaqes. ACM, New York~ 434-445. Google ScholarGoogle Scholar

Index Terms

  1. A type system equivalent to flow analysis

            Recommendations

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in

            Full Access

            • Published in

              cover image ACM Transactions on Programming Languages and Systems
              ACM Transactions on Programming Languages and Systems  Volume 17, Issue 4
              July 1995
              129 pages
              ISSN:0164-0925
              EISSN:1558-4593
              DOI:10.1145/210184
              Issue’s Table of Contents

              Copyright © 1995 ACM

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 1 July 1995
              Published in toplas Volume 17, Issue 4

              Permissions

              Request permissions about this article.

              Request Permissions

              Check for updates

              Qualifiers

              • article

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader