String::truncate doc: also fails if not a char boundary
auto merge of #17794 : SimonSapin/rust/patch-8, r=alexcrichton