I agree with you that the question as worded runs counter to current legal interpretations of the ADA, which disallow questions about past conditions. I was pointing out to TableMD that his revulsion over the OP's worry is silly since the OP's worry was unfounded in the first place. It's like my wife getting mad at me for making our son cry over an A-, when in fact I only asked whether or not he got an F.
I do think it's reasonable to ask about current impairment. Past mental health problems are off limits according to the ADA, but current ones aren't. As far as asking about the potential for impairment if treatment lapses, I lack the background knowledge to have an informed opinion about whether such a question would run counter to the ADA.
I do have some relevant background and have also consulted a disability lawyer who has dealt with medical boards. He says that the wording of the NC question is "problematic" from an ADA perspective. Essentially, the ",if untreated," language is, under legal deconstruction of English, a parenthetical (rather than a restrictive) statement that can for all intents and purposes be ignored. In other words, the sentence may be read as if it had no such statement. It would then read, "In the past five (5) years, have you had, or have you been told you had, a mental health or physical condition (not referenced above) which in any way limits or impairs or could limit or impair your ability to practice medicine in a competent or professional manner?".
Such a question would be impermissible under the ADA.
Not to mention that it is asking an applicant to predict the future! Let's see, any doc over 50 probably has several physical conditions (occult ASCVD, HBP, DM, etc) that could AT SOME POINT limit or impair their ability to practice medicine in a competent or professional manner. Are they going to haul everyone in for total body scanning, etc. (or simply send them all off to drug rehab for megabucks? Google "Diagnosing for Dollars")
This is going to be discussed in a panel at the upcoming FSMB meeting April 27 in Charlotte (Sheraton La Meridien, Breakout Session #3 9:15-10 AM) that will include the Chief Counsel for the NCMB, who probably wrote the question. If anyone is nearby, just walk in (there's usually no security) and if asked say you are a medical student and want to get a glimpse of medical regulation in progress, and to see what your Federation is doing about your wellbeing.