Made signifcant improvements on generating type errors. This is mainly for attempting to use array indexing on identifiers.