more extensive assert statement checks (warn for side effects), moved to separate class