Edit this page on GitHub

Dropped: General Type Projection

Scala so far allowed general type projection T#A where T is an arbitrary type and A names a type member of T.

Scala 3 disallows this if T is an abstract type (class types and type aliases are fine). This change was made because unrestricted type projection is unsound.

This restriction rules out the type-level encoding of a combinator calculus.

To rewrite code using type projections on abstract types, consider using path-dependent types or implicit parameters.