new version, based on Inst and Vec<Var *>