Java SAM Typed Closures: A Sound and Complete Type Inference System for Nominal Types

  • Authors:
  • Marco Bellia;M. Eugenia Occhiuto

  • Affiliations:
  • Dipartimento di Informatica, Università di Pisa, Italy. {bellia,occhiuto}@di.unipi.it;Dipartimento di Informatica, Università di Pisa, Italy. {bellia,occhiuto}@di.unipi.it

  • Venue:
  • Fundamenta Informaticae - Concurrency, Specification and Programming
  • Year:
  • 2013

Quantified Score

Hi-index 0.00

Visualization

Abstract

The last proposal for Java closures, as emerged in JSR 000335, is mainly innovative in: 1 Use of nominal types, SAM types, for closures; 2 Introduction of target types and compatibility for a contextual typing of closures; 3 Need for a type inference that reconstructs the omitted type annotations of closures and closure arguments. The paper provides a sound and complete type system, with nominal types, for such a type inference and discusses role and formalization of targeting and of compatibility in the designed inference process.