Type-checking Software Product Lines -- A Formal Approach

kaestner@cs.cmu.edu (C. Kästner, S. Apel)
Fri, 10 Jan 2025 13:48:21 GMT

Christian Kästner, and Sven Apel. Type-checking Software Product Lines -- A Formal Approach. In Proceedings of the 23rd IEEE/ACM International Conference on Automated Software Engineering (ASE), ISBN 978-1-4244-2187-9, pages 258--267, Los Alamitos, CA: IEEE Computer Society, September 2008.

A software product line (SPL) is an efficient means to generate a family of program variants for a domain from a single code base. However, because of the potentially high number of possible program variants, it is difficult to test all variants and ensure properties like type-safety for the entire SPL. While first steps to type-check an entire SPL have been taken, they are informal and incomplete. In this paper, we extend the Featherweight Java (FJ) calculus with feature annotations to be used for SPLs. By extending FJ's type system, we guarantee that – given a well-typed SPL – all possible program variants are welltyped as well. We show how results from this formalization reflect and help implementing our own language-independent SPL tool CIDE.