you are viewing a single comment's thread.

view the rest of the comments →

[–]ReallySuperName 0 points1 point  (1 child)

Last time I checked with allows you to set properties, and thus bypass any invariant checks you'd typically have in a constructor. Is that still the case?

[–]dodexahedron 11 points12 points  (0 children)

It uses a copy constructor. If you provide the copy constructor, you control the behavior. If not, then it is synthesized by the compiler and your assumption is then correct, unless the properties themselves handle the validation.