dotnet / dotnet/dotnet-api-docs
In DeepCopy, if you have to copy the string, then what is MemberwiseClone doing?
- Dominant language
- C#
- Stars
- 949
- Forks
- 1.7k
- Avg merge
- 3d 27m
- Merged PRs (30d)
- 49
Description
Why do you have to manually copy values over if you have already called MemberwiseClone?
other.Name = String.Copy(Name);
---
#### Document Details
⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*
* ID: e10c524e-0f81-cfa4-5ce9-6855c049c1e4
* Version Independent ID: 747f5fd4-cace-1476-77e4-5839b96dcaf0
* Content: [Object.MemberwiseClone Method (System)](https://docs.microsoft.com/en-us/dotnet/api/system.object.memberwiseclone?view=netframework-4.7.2)
* Content Source: [xml/System/Object.xml](https://github.com/dotnet/dotnet-api-docs/blob/master/xml/System/Object.xml)
* Product: **dotnet-api**
* GitHub Login: @dotnet-bot
* Microsoft Alias: **dotnetcontent**
Contributor guide
Assessment
This issue has not been assessed yet.