An intermediate data structure that carries both the type A
and its representation Repr
.
An intermediate data structure that carries both the type A
and its representation Repr
.
Phantom type describing the structure of A
To sum up: we are given the types of the possible A
values in a Coproduct
structure and we want to
define how to traverse this structure to accumulate all the values in a List
.
Derives a Values[A]
instance given a representation Repr
of type A
in terms of Coproduct
, and a given
a ValuesAux[A, Repr]
instance.
Derives a Values[A]
instance given a representation Repr
of type A
in terms of Coproduct
, and a given
a ValuesAux[A, Repr]
instance.
Type of the representation of A
as a Coproduct
.
A Coproduct
is recursively defined as either CNil
or H :+: T
, where T
is a
subtype of Coproduct
.
For instance, a sealed trait that is extended by only one case object Foo
can have the following
representation: Foo.type :+: CNil
.
Isomorphism between A
and Repr
. Shapeless is able to provide such an implicit value for any
sealed type