Fix LDOMBasicString assignment operator

See #416. If the source and destination strings point to the same place, then this will result in undefined behavior (delete[] the ptr and then memcpy() from it).