Chinup, the reason I say usually not more than 90 days inpatient is because the long-term effectiveness of treatment hinders a lot on the transition. Meaning how well you return to normal life while maintaining new coping mechanisms and healthy behaviors without returning to old and unhealthy ones is a big factor in how effective the treatment will be. You will hopefully be learning a lot about yourself and the disorders you are dealing with, but knowledge alone is not the solution. Different therapies can help shed a lot of insight to why you are struggling so much with a particular disorder, but it is not insight alone that brings change.
Knowledge and insight, combined with action, is what truly brings about change. And in my opinion, it is more about learning about learning how to deal with our behavior rather than to change our behavior. It usually seems pretty obvious what we need to change in order to correct our behavior with things like eating disorders and addiction- just stop doing drugs, start eating and stop puking, right? But it never is that simple in practice. That is where different therapies can really help, once you better understand why you do something then you can really begin to attack to root of the problem and bring about real change. More than just resisting an impulse or forcing yourself to do it, understanding why. Eating disorders are a perfect example of this- anorexia, in general, has a psychological cause rather than a physical one; in general people are not anorexic as result of a physical ailment but instead a phycological one. Often it is rooted in a distorted self-image, and this distortion is often caused by childhood trauma. There are other reasons, and you may be different, but this is the most common cause.
So, all that to say, it is important to understand and address the root cause of the disorder not just the symptoms. Addictions, in general, also have a root cause much deeper than just taking a drug and becoming physically dependent. There are things that will make you more susceptible to addiction as well as things that will lower your risk.
One thing that you seem to have going for you is an openness and receptiveness. It is a difficult time and being open and willing to change is a huge part of the battle. The counselors and staff will be telling you one thing but your disease will try to find every way to resist. Like how you mention you're not an alcoholic(which Ill believe) but you're afraid of not having anything. This fear is the lie of addiction. You don't need it and you are stronger without it and despite possibly having this cognitive realization, you will still be compelled to find ways around this reality.
To be equally honest, a high level of intelligence might actually work against you. This is a time where you need to focus on yourself and work on yourself. It's more of an emotional battle than an intellectual one. Some of the exercises might seem extremely elementary, but most of us addicts are learning emotions at an elementary level in early recovery. Don't be afraid to make dumb mistakes, try to look at mistakes and embarrassment as part of the learning process.
And to answer your last question... I believe it is integral to a full recovery. There is clearly a correlation and I believe there is a link between eating disorders and substance use disorders. "Up to 50% of individuals with eating disorders abused alcohol or illicit drugs, a rate five times higher than the general population. Up to 35% of individuals who abused or were dependent on alcohol or other drugs have also had eating disorders, a rate 11 times greater than the general population."
link
Substance use disorders are generally not the result of physical dependence and rewarding stimulation(high), although they do add to the problems and difficulty. The one common underlying link between all addicts is a poorly developed or poorly functioning emotional regulatory system. Either something went wrong and the person is no longer able to properly regulate emotions, or the person never really had a strong ability to regulate to begin with. And there are so many factors that affect this, from biological to psychological to social. who you are, who you are around, and the environment you are in all play a role. It is why the disease is biopsychosocial. Apart from the more apparent connections, like being moody from not eating leading to drug use, I believe there are also deeper ones unique to the individual. Like eating disorders, substance use disorders also have a deeper root cause than getting high/intoxicated. Things like cognitive distortions and childhood trauma are often at the root of the cause as well. Without addressing the root cause and learning new coping methods and ways to deal with thoughts and feelings, relapse is almost guaranteed.
TLD:DR
To answer your last question simply, yes, I think it's inevitable that whatever problems you haven't dealt with and have been covering up with drugs will resurface once the rugs are gone. You don't have to go back and revisit all the traumatic events in your life, but the ones that are still hanging out will need something done with them. This is where "one day at a time" comes into play. You don't need to solve a lifetime of problems during the months you stay at the rehab. This is just the beginning of a lifetime of change. The thought the "recovery is forever" is initially more scary than it needs to be. Self-discovery and self-exploration are forever as well, but when taken one day at a time there is always time.