Quantum theory and the equivalence principle