Given
class Bird {
name: String = "DEFAULT"
colloquialName: String = name
}
evaluating
new Dynamic { name = "Pigeon" }.toTyped(Bird)
results in
new Bird {
name = "Pigeon"
colloquialName = "DEFAULT" // <- unexpected
}
The same holds for the toTyped definition on Map, so the following produces the same result:
new Dynamic { name = "Pigeon" }.toMap().toTyped(Bird)
Given
evaluating
results in
The same holds for the
toTypeddefinition onMap, so the following produces the same result: