In both situations, state and local laws have at times prohibited public school teachers from teaching in classrooms in church buildings. I don't think the Constitution requires that prohibition. In fact, I think that prohibition is in violation of the Constitution. Congress shall make no law respecting an establishment of religion. There must not be an official religion.
All religions are equal.
In a way, that's true. It's a legal expression of the principle that the church and the state are two different and completely separate institutions. But, in a way, it goes further, because it says that while there is only one state in a given place, there is not one church, but many churches. And in another way, it doesn't go nearly that far, because, rather than requiring the state to keep away from churches, it requires the state to approach churches the same way it approaches other non-profit institutions. So, let's keep some perspective about separation of church and state.