[libcxx] applies changes regarding post-commit feedback to #75259 (#76534)

Some of the feedback was also relevant to other files, and has been
applied there too.

GitOrigin-RevId: f0ea888e01aabcb131a8931b9e1fe1c5212a6cba
10 files changed