syntax: remove dead @mut Visitor impl (only used in tests).

Also, move some code only uses in the tests into the test module, and
replace some needless @mut ~[] with plain ~[].
auto merge of #10117 : huonw/rust/dead-visits, r=sanxiyn

Used nowhere, and these are likely incorrect anyway: self needs to be
dereferenced once more otherwise the method calls will be reusing the
current impl... bam! Infinite recursion.