Removed some redundant code from tstring.cpp.
Reduced unnecessary copies of shared_ptr when copying String.