'Emit a warning if any elements of ``value`` will be truncated when
``value`` is assigned to self.'

def _check_string_truncate(self, value):

    value = np.asanyarray(value, dtype=self.dtype.type)
    if (value.size == 0):
        return
    value_str_len = np.char.str_len(value).max()
    self_str_len = int(re.search(u'(\\d+)$', self.dtype.str).group(1))
    if (value_str_len > self_str_len):
        warnings.warn(u'truncated    right    side    string(s)    longer    than    {}    character(s)    during    assignment'.format(self_str_len), StringTruncateWarning, stacklevel=3)
