This is a partial fix, because the design of DiffContext and how the modifications are propagated is fundamentally broken.
For example following case won't work:
case class Address(house: Int, street: String)
case class Person(name: String, address: Address)
val add = Diff.summon[Address].ignore(_.house)
val d = Diff
.summon[Person]
.modify(_.address)
.setTo(add)
.modify(_.address.street).ignore
The second modification won't work and there is no good way to fix it.
Relates to #418
This is a partial fix, because the design of
DiffContext
and how the modifications are propagated is fundamentally broken.For example following case won't work:
The second modification won't work and there is no good way to fix it.