stateless
stateless copied to clipboard
Reduce data layer accidental complexity
When defining an association between entities, we need something like this:
trait Person[Pr] {
type P[_]
type Ad; val Address: Address[Ad]
val optAddress: OptionalAlg.Aux[P, Address.P, Ad]
}
This is very noisy. One of the ideas that we'd like to apply is the next one:
trait Person[Pr] {
type P[_]
type Ad: Address
val optAddress: OptionalAlg.Aux[P, Ad.P, Ad]
}
However, at first glance, it seems to be impossible to implement this idea with macros. Is there any other way to get something similar to this?