fixed missing top-node-selector
changed order of externals and extend output
continued work on visitor