Move module name checks to the grammar checker.

Make some errors shorter.