Small cleanup to pruneVisit functions

Instead of walking all ASTs and filtering for SymExprs or DefExprs, collect
SymExprs or DefExpers and walk over them directly.  Also replaced some Vecs
with std::vectors.
Merge pull request #33 from daviditen/pruneVisitCleanup

Small cleanup to pruneVisit functions
[Reviewed by hildeth]