I did get an erection when I went to my lady kid doctor when I just turned 18. I was going to switch to family doctor, but I got wrestler's ear right before going to college towards end of the wrestling season. This was around mid 80s.
She always made me get completely undressed for the sports physicals I've had with her, but after draining the ear with a syringe and putting a cotton gauze over it, she told me that she should check other parts of my body to see if there are any skin conditions from wrestling.
She told me to undress, and I undressed down to my shorts and underwear, but she told me to remove my shorts and underwear also. It was kind of a shock as I was naked in front of her and her nurse again, even though I had sports physical with her just couple months ago.
She gave me a skin check with me standing, and then decided to give me a hernia exam, and examine my testicles also, and checked my foreskin.
She then told me to lie down on the side on the exam table, and gave me a first rectal exam, saying that "We should check down there since you will be also wrestling in college, and make sure you are in top shape." During the rectal exam, I was getting erect.
She told me to lie down on my back, and I did, but kept both hands covering the crotch. She told me to put my hands to my side, and she asked me if it hurt when my penis was like that, as she tapped my penis gently couple of times. I instinctively covered myself again and remember being embarassed.
I remember her telling me that reaction like this is normal, and not to be embarassed, and told me to get dressed, and that she'll give me a prescription for an antibiotic.
I went to her for a cold two or three times (can't remember exactly) , other than the sports physical I had every year, I remember being completely undressed, and she always examined my genitals, even if I was there for a cold or flu. I think she was very old fashioned, as she looked like she was already in her 70's.