A theory of prepositional types