SI-7362, crash in presentation compiler.

Code by retronym, test by huitseeker, I just move stuff around.
More useful checkfile output in interactive tests.

I resisted the urge to fix "aksTypeCompletion" for as long
as I possibly could. While I was there I threw in what seem
to be like significant output improvements, but you tell me.
Merge pull request #2406 from paulp/issue/7362

SI-7362, crash in presentation compiler