refs: document _next_name()

If it's not documented, it doesn't show up in the docs (and we really
should document, anyway).