Title
Simplicitly: foundations and applications of implicit function types
Abstract
Understanding a program entails understanding its context; dependencies, configurations and even implementations are all forms of contexts. Modern programming languages and theorem provers offer an array of constructs to define contexts, implicitly. Scala offers implicit parameters which are used pervasively, but which cannot be abstracted over. This paper describes a generalization of implicit parameters to implicit function types, a powerful way to abstract over the context in which some piece of code is run. We provide a formalization based on bidirectional type-checking that closely follows the semantics implemented by the Scala compiler. To demonstrate their range of abstraction capabilities, we present several applications that make use of implicit function types. We show how to encode the builder pattern, tagless interpreters, reader and free monads and we assess the performance of the monadic structures presented.
Year
DOI
Venue
2018
10.1145/3158130
Proceedings of the ACM on Programming Languages
Keywords
Field
DocType
Dotty,Scala,implicit parameters
Programming language,Abstraction,Scala,Computer science,Implicit function,Implementation,Compiler,Theoretical computer science,Interpreter,Monad (functional programming),Semantics
Journal
Volume
Issue
ISSN
2
POPL
2475-1421
Citations 
PageRank 
References 
0
0.34
0
Authors
6
Name
Order
Citations
PageRank
Martin Odersky12261170.39
Olivier Blanvillain221.39
Fengyun Liu312.39
Aggelos Biboudis4164.78
Heather Miller5457.63
Sandro Stucki6232.07