When you pass a list to a method that you pass to the pointer to the specified list, why do you change the "source" list when it changes inside your method. If you want to change a copy of the list, you just need to create it. In the code that CopyTest1 calls, you can create a new list based on the original list:
public void CallsCopyTest1() { var originalList = new List<int>(); var newList = new List<int>(originalList); var copyTest = new CopyTest1(newList);
source share