H
Herfried K. Wagner [MVP]
Dennis said:Doesn't that only work if all fields of the structure are value type. If
one
is a reference type, won't it be just a pointer to the same object as the
copy?
Yes, that's true. What you want to do is a deep copy of the object.
Nevertheless, creating deep copies is non-trivial if there are circular
references.