rename TermContext to State

just an automated refactoring -- intrusive but should be clean