void DocumentLifecycle::ensureStateAtMost(State state) { ASSERT(state == VisualUpdatePending || state == StyleClean || state == LayoutClean); if (m_state <= state) return; ASSERT(canRewindTo(state)); m_state = state; }
void DocumentLifecycle::ensureStateAtMost(LifecycleState state) { DCHECK(state == VisualUpdatePending || state == StyleClean || state == LayoutClean); if (m_state <= state) return; #if DCHECK_IS_ON() DCHECK(canRewindTo(state)) << "Cannot rewind document lifecycle from " << stateAsDebugString(m_state) << " to " << stateAsDebugString(state) << "."; #endif m_state = state; }