For reasons unbeknownst to me one is not supposed to plant tomatoes and potatoes in close proximity to one another. But what about putting compost containing tomatoes onto potatoes or vice versa?
The potential problem is due to the fact that potatoes and tomatoes are closely related, both members of the nightshade family, Solanum.
This means, they are both susceptible to a few fungal diseases, which can "jump" from one type of plant to the other. Note that there are more members of the solanum family that are less susceptible, but can carry the diseases nonetheless, e.g. eggplant / aubergine (S. melongena), and even more distant relatives like (bell) peppers and chillies (Capsicum annuum) and petunias.
Late blight, the culprit in the Irish potatoe famine, is an especially robust customer, the spores can survive easily in the soil, even for years, which is one reason crop rotation is recommended. But above all, infected plants should not go into your compost heap.
So to get back to the original question:
Compost containing originally healthy plant parts is fine, if diseased plants were composted, there is the risk of spreading the infection. This is not limited to related plants in the garden beds right now, but you may be introducing the fungus to your soil, "contaminating" it for a few seasons.
I see nothing wrong with putting potatoes in by tomatoes because it will not seed as long as the spout is off, ,which will help. for tomatoes by potatoes I would be best off not doing. The seeds could start growing. Thou this can be good fertilizer you will have to put up with all sorts of tomatoes coming up. Not saying that you couldn't weed them out. Otherwise go ahead.
Also I can see if the potato is fairly well just a little old the roots of the tomatoes will just go around. At least I am thinking...