Is there any work in type theory where no base types are assumed, e.g., that there are only function types in place ($t_1 \to t_2$ is a type whenever $t_1$ and $t_2$ are types)?
If not, are there specific reasons for that?
Is there any work in type theory where no base types are assumed, e.g., that there are only function types in place ($t_1 \to t_2$ is a type whenever $t_1$ and $t_2$ are types)?
If not, are there specific reasons for that?
System F seems to satisfy your criteria, provided you allow other type constructors. Types are constructed from $\rightarrow$ and $\forall$. There are no base types like those of, say, system T (i.e. $\mathsf{nat}$).
In many formal systems we work with metavariables, which are meta-level symbols which stand for unknown, arbitrary or yet-to-be-determined entities. For instance, in propositional calculus we say things like "$A \land B$ is equivalent to $B \land A$" -- here $A$ and $B$ are metavariables standing for any formulas.
We can do the same thing in type theory. From your examples I surmise that you have in mind simple types, so let us stay with those. It is perfectly OK, and even useful, to consider types in which metavariables occur, as then you can say things like "$\lambda (x : A \times B). (\pi_2 x, \pi_1 x)$ is an isomorphism from $A \times B$ is isomorphic to $B \times A$". In your question you yourself used the metavariables $t_1$ and $t_2$ when you spoke of the type $t_1 \to t_2$.
Without metavariables and without base types the type theory becomes trivial because we cannot form any types at all.
a * b * c
is a primitive ternary product, which is neither (a * b) * c
nor a * (b * c)
. If you allow the product of an empty list that's just a roundabout way of positing a primitive type, namely the unit type. ML does not allow it, Haskell does.
$\endgroup$
Commented
Aug 14, 2020 at 17:00