Fixed #16905, #8579, #3055, #19844 -- Added extensible checks (nee valid...

...ation) framework.

This is the result of Christopher Medrela's 2013 Summer of Code project.

Thanks also to Preston Holmes and Tim Graham for the review notes along the way.