move vars decls where vars are used