added assertion on method override.