refactors importers

Introduces better names, factors out recreation of symbols, trees, types
and completes into separate methods, so that they can be overridden in
specialized importers.

The original motivation for this refactoring was to support JIT
compilation of macros, but I think that most of the introduced
improvements to code quality will be useful in trunk.
refactors macro compilation
refactors macro runtimes