Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(717)

Unified Diff: third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp

Issue 1878473002: ASSERT -> DCHECK in core/editing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Output info for some DCHECKs, add TODOs. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp
diff --git a/third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp b/third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp
index 12684a2290370d821153a30257f454570ffe5202..cdd4fbd5d2f8c907a9a35ceac6e6170d25c3cd6f 100644
--- a/third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp
+++ b/third_party/WebKit/Source/core/editing/commands/BreakBlockquoteCommand.cpp
@@ -87,7 +87,7 @@ void BreakBlockquoteCommand::doApply(EditingState* editingState)
// This is a scenario that should never happen, but we want to
// make sure we don't dereference a null pointer below.
- ASSERT(!endingSelection().isNone());
+ DCHECK(!endingSelection().isNone());
if (endingSelection().isNone())
return;
@@ -143,7 +143,7 @@ void BreakBlockquoteCommand::doApply(EditingState* editingState)
// startNode is the first node that we need to move to the new blockquote.
Node* startNode = pos.anchorNode();
- ASSERT(startNode);
+ DCHECK(startNode);
// Split at pos if in the middle of a text node.
if (startNode->isTextNode()) {
@@ -151,14 +151,14 @@ void BreakBlockquoteCommand::doApply(EditingState* editingState)
int textOffset = pos.computeOffsetInContainerNode();
if ((unsigned)textOffset >= textNode->length()) {
startNode = NodeTraversal::next(*startNode);
- ASSERT(startNode);
+ DCHECK(startNode);
} else if (textOffset > 0) {
splitTextNode(textNode, textOffset);
}
} else if (pos.computeEditingOffset() > 0) {
Node* childAtOffset = NodeTraversal::childAt(*startNode, pos.computeEditingOffset());
startNode = childAtOffset ? childAtOffset : NodeTraversal::next(*startNode);
- ASSERT(startNode);
+ DCHECK(startNode);
}
// If there's nothing inside topBlockquote to move, we're finished.

Powered by Google App Engine
This is Rietveld 408576698