Scala 3 — Book

Summary

Language

This chapter provides an introduction to most Contextual Abstractions topics, including:

These features are all variants of the core idea of term inference: given a type, the compiler synthesizes a “canonical” term that has that type.

A few more advanced topics aren’t covered here, including:

  • Conditional Given Instances
  • Type Class Derivation
  • Context Functions
  • By-Name Context Parameters
  • Relationship with Scala 2 Implicits

Those topics are discussed in detail in the Reference documentation.

Contributors to this page: