Published September 30, 2020 | Version v1
Software Open

ιDOT: A DOT Calculus with Object Initialization (Coq Formalization)

  • 1. University of Alberta
  • 2. University of Waterlooo
  • 3. University of Waterloo

Description

This is the artifact for our OOPSLA'20 paper that presents ιDOT, a Dependent Object Types calculus with a type and effect system to ensure safe initialization of objects. This artifact contains the proof of type safety for the ιDOT calculus, formalized in the Coq proof assistant.

Paper abstract:

The Dependent Object Types (DOT) calculus serves as a foundation of the Scala programming language, with a machine-verified soundness proof. However, Scala's type system has been shown to be unsound due to null references, which are used as default values of fields of objects before they have been initialized. This paper proposes ιDOT, an extension of DOT for ensuring safe initialization of objects. DOT was previously extended to κDOT with the addition of mutable fields and constructors. To κDOT, ιDOT adds an initialization effect system that statically prevents the possibility of reading a null reference from an uninitialized object. To design ιDOT, we have reformulated the Freedom Before Commitment object initialization scheme in terms of disjoint subheaps to make it easier to formalize in an effect system and prove sound. Soundness of ιDOT depends on the interplay of three systems of rules: a type system close to that of DOT, an effect system to ensure definite assignment of fields in each constructor, and an initialization system that tracks the initialization status of objects in a stack of subheaps. We have proven the overall system sound and verified the soundness proof using the Coq proof assistant.

Files

iDOT-calculus.zip

Files (3.6 MB)

Name Size Download all
md5:7e1a7be293e258dd63cf6d68b856e34a
3.2 MB Preview Download
md5:23b93828552cc55df401f8c8e87ecac0
1.1 kB Download
md5:0fe3f1060eebdf51c524082b82c526cd
336.9 kB Preview Download