IMPLICITS IN SCALA 3
summary
Scala 3 replaces the single implicit keyword with three concrete mechanisms and shows how they solve real problems: extension, using, given replace ad-hoc implicits with built‑in extension methods, explicit context parameters (multiple and anonymizable), and named or anonymous synthesizable instances. The compiler gives clearer diagnostics, givens are lazy by default, summon replaces implicit, and imports require import a.given / wildcard excludes givens so implicits no longer silently leak into scope. Examples include deriving HttpResponse[Option[T]] from HttpResponse[T].
AI-written summary · about
chapters (15)
- 0:00Scala 3 implicits intro
- 1:03Scala 2 implicits flaws
- 3:29Scala 2 implicit patterns
- 6:21Why Scala 3 redesigned implicits
- 8:28Scala 3’s contextual changes
- 9:11Extension methods in Scala 3
- 11:20Using clauses replace params
- 13:07Clarity with using clauses
- 17:03Given replaces implicit defs
- 18:50Better errors with given
- 19:54Import syntax for givens
- 22:00Type classes in Scala 3
- 25:14Scala 2 vs Scala 3 implicits
- 26:58Final thoughts on Scala 3 implicits
- 27:40Q&A
related talks
29mSay goodbye to implicits - contextual abstractions in Scala 3
36mSay goodbye to implicits contextual abstractions in Scala 3
42mImplicits Revisited
46mImplicits Inspected and Explained
01h 04mKeynote - What to Leave Implicit
43mDon't Fear the Implicits: Everything You Need to Know About Typeclasses
30mLessons Learned from 15 Years of Scala in the Wild
48mKeynote: Some Mistakes We Made When Designing Implicits
