showdict: use endof instead of sizeof

Sometimes, the output showed the truncation mark "…" even
when nothing was truncated.
Merge pull request #9463 from JuliaLang/rf/dict-show-utf8

showdict: use endof instead of sizeof