Open
Description
Consider:
@Freezed()
class A {
A(Map<String, Object?> map);
}
Where the generated code is:
augment class A {
augment A(
prefix0.Map<prefix0.String, prefix0.Object?> map,
) : map = {'c': 42}; // Notice how we hard-coded the content
final prefix0.Map<prefix0.String, prefix0.Object?> map;
}
In theory, print(A({'a': 0}).map
should always print {'c': 42}
. But somehow, this prints {'a': 0}
.
This makes no sense, as the parameter is unused here, and the field initialization is hard-coded.