In Scala implicit parameters are everywhere, starting from the infamous ExecutionContext
that is needed to execute any Future
.
However as soon as you require 2 implicit instances of the same type in a function, you compilation fails and you have to make one of them non-implicit. And it works, you can still pass the parameter explicitly where it’s needed but you miss the point of not having to add extra parameter to the function call.
Let me walk you through an example and to make it something useful, let’s try to fix the useless stack traces that one might get when using async code.
Continue reading “Getting rid of implicit parameters”