Static helper functions for checking coding pre-/post-conditions.