call assignment operator instead of memcpy on data member assignment