pub fn build_tries( typeenv: &TypeEnv, termenv: &TermEnv) -> BTreeMap<TermId, TrieNode>
Construct the tries for each term.