adding end() called only once sanity check