Continued parser implementation.
Type instance references are fixed up after parsing complex types. Initial implementation of document traversal using visitor pattern.