There was a lot in TOS about Kirk wrestling with the loneliness of command, but that wasn't about being literally unaccompanied by other people, just about it being lonely at the top, having to bear the responsibility for command decisions alone -- and also about the demands of the job not leaving him room to find love and happiness with a woman.
That's another reason the "I'll die alone" line lands badly. It comes out of nowhere. It doesn't feel like it's in character, it's just a random, maudlin insertion.
OK. I see your point. Not so much lacking friends, but lacking a spouse/companion.
You're right. No beach to walk on
