Display compile errors - rebase from @jeremybanks

Rebase of #1728