semantic: Remove refrep and fold functionality into exptyper.

I also fixed import test 24 and aggregate test 10
while doing the refactoring.