Ask any question about EPFL courses, lectures, exercises, research, news, etc. or try the example questions below.
DISCLAIMER: The Graph Chatbot is not programmed to provide explicit or categorical answers to your questions. Rather, it transforms your questions into API requests that are distributed across the various IT services officially administered by EPFL. Its purpose is solely to collect and recommend relevant references to content that you can explore to help you answer your questions.
Over the past decade, the Scala community has shown great interest in using type-level programming to obtain additional type safety. Unfortunately, the lack of support from the Scala compiler has been a barrier to the adoption of that technique, notably due to its negative impact on compilation times. In this thesis, we present three techniques for type-level programming in Scala. First, we explain the status quo, implicits, and show how we can divert them from their intended use to write ad hoc type-level programs. Second, we propose a generalization of Scala's singleton types, which adds the ability to manipulate term-level programs at the type level. Third, we introduce match types, a type-level equivalent of pattern matching, which we implemented in the Scala~3 compiler. Throughout this dissertation, we demonstrate the practicality of our newly introduced techniques, by the means of case studies and examples. Our performance evaluation shows that our new techniques outperform the status quo in terms of binary sizes and compilation times.
Aleksander Slawomir Boruch-Gruszecki
Aleksander Slawomir Boruch-Gruszecki
Martin Odersky, Aleksander Slawomir Boruch-Gruszecki, Yichen Xu