Factor out compiler interface compatibility layer.

Move collection (a class `Compat`) of compatibility hacks into separate
file. This aids understanding of the code as both Analyzer and API make
use of that class and keeping it `Analyzer.scala` file suggested that
it's used only by Analyzer.
Factor out class file lookup out of Analyzer class.

Move logic related to class file lookup to separate class that
can be reused outside of Analyzer class.