On the Modularity of Feature Interactions

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

Chang Hwan Peter Kim, Christian Kästner, and Don Batory. On the Modularity of Feature Interactions. In Proceedings of the 7th ACM International Conference on Generative Programming and Component Engineering (GPCE), ISBN 978-1-60558-267-2, pages 23--34, New York, NY: ACM Press, August 2008.

Feature modules are the building blocks of programs in software product lines (SPLs). A foundational assumption of feature-based program synthesis is that features are composed in a predefined order. Recent work on virtual separation of concerns reveals a new model of feature interactions that shows that feature modules can be quantized as compositions of smaller modules called derivatives. We present this model and examine some of its unintuitive consequences, namely, that (1) a given program can be reconstructed by composing features in any order, and (2) the contents of a feature module (as expressed as a composition of derivatives) is determined automatically by a feature order. We show that different orders allow one to “adjust” the contents of a feature module to isolate and study the impact of interactions that a feature has with other features. Using derivatives, we show the utility of generalizing safe composition (SC), a basic analysis of SPLs that verifies program type-safety, to prove that every legal composition of derivatives (and thus any composition order of features) produces a typesafe program, which is a much stronger SC property.