Is it actually possible to have a field x
which can get set in the constructor
but is frozen with dataclasses
in python?
@dataclass
class A():
x : int
a = A(x=4)
a.x = 4 # Would raise an exception because its read-only.
I could not find out how that should work with @property
or any other feature?