A more informative error message.

Closes #7336
Merge pull request #12773 from cachedout/7336

A more informative error message.