fix missing_doc lint on private traits

Fixes #10069.