Reduced an unnecessary copy of shared_ptr when copying a String.