Of course, nobody can really know what goes on in those little snakey brains, lol! But my best guess after many years of caring for, and observing them, is that they probably can't form emotional attachments to people or animals (at least in the same way we think of emotions). However, I have seen evidence that they can recognize people or particular animals that have either been good to them (such as feeding) or that have caused distress to them (teasing, scaring, making fast, scary movements, etc). I also believe that they are very much creatures of habit, and tend to like things to stay the way they are. Any change is somewhat stressful, even if it is a change for the better. So it does not really surprise me if a snake has gotten used to a cage mate, even if it was stressful at the beginning, and sometimes even stressful now. Heck, look how many PEOPLE stay in horrible, stressful marriages, in part just because change would be so difficult and stressful, and we fear the unknown. And we are SUPPOSED to be smart enough to figure such things out, haha!
My feeling is that if two snakes have been together for a long time, the stress level has probably gone down a lot since the introduction, since they had to find ways to deal with each other and desensitize themselves to the constant and unnaturally close proximity. They most likely will do ok together at that point, although if one of them ever gets stressed due to illness or some other reason, the additional stress of a cage mate may again rear its ugly head. Separating now will cause some stress for a while, just as adjusting to a new home causes stress when I ship out a new pet. But I don't feel there will be the emotional pain of missing a good buddy, just the temporary stress of a change from the old, known situation. But as I said, it is just my opinion - I am not a telepathic "snake whisperer", lol!