rewrite dependency traversal using pickler visitor