visitor: fix use-after-free (using ASAN)
visitor: decrease nodes.count on free