Switch naming from types to elements.

This makes more sense conceptually since we are matching parsing and representing the syntax tree, not a type graph.

Since this is a fundamental API change (with more to come) we also bump the version to be working towards a v4.

@swankjesse