I have a struct, MyStruct, that has a private member private bool[] boolArray; and a method ChangeBoolValue(int index, bool Value). <
MyStruct
private bool[] boolArray;
ChangeBoolValue(int index, bool Value)
Struct is copied when passed right? So:
public static class StructExts { public static T Clone ( this T val ) where T : struct => val; }
Usage:
var clone = new AnyStruct ().Clone ();