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

Side by Side Diff: third_party/WebKit/Source/core/editing/serializers/Serialization.cpp

Issue 2727843003: Replace RELEASE_ASSERT with CHECK in core/{dom,editing,html} (Closed)
Patch Set: Add a comment Created 3 years, 9 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights
3 * reserved. 3 * reserved.
4 * Copyright (C) 2008, 2009, 2010, 2011 Google Inc. All rights reserved. 4 * Copyright (C) 2008, 2009, 2010, 2011 Google Inc. All rights reserved.
5 * Copyright (C) 2011 Igalia S.L. 5 * Copyright (C) 2011 Igalia S.L.
6 * Copyright (C) 2011 Motorola Mobility. All rights reserved. 6 * Copyright (C) 2011 Motorola Mobility. All rights reserved.
7 * 7 *
8 * Redistribution and use in source and binary forms, with or without 8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions 9 * modification, are permitted provided that the following conditions
10 * are met: 10 * are met:
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 String CreateMarkupAlgorithm<Strategy>::createMarkup( 256 String CreateMarkupAlgorithm<Strategy>::createMarkup(
257 const PositionTemplate<Strategy>& startPosition, 257 const PositionTemplate<Strategy>& startPosition,
258 const PositionTemplate<Strategy>& endPosition, 258 const PositionTemplate<Strategy>& endPosition,
259 EAnnotateForInterchange shouldAnnotate, 259 EAnnotateForInterchange shouldAnnotate,
260 ConvertBlocksToInlines convertBlocksToInlines, 260 ConvertBlocksToInlines convertBlocksToInlines,
261 EAbsoluteURLs shouldResolveURLs, 261 EAbsoluteURLs shouldResolveURLs,
262 Node* constrainingAncestor) { 262 Node* constrainingAncestor) {
263 if (startPosition.isNull() || endPosition.isNull()) 263 if (startPosition.isNull() || endPosition.isNull())
264 return emptyString; 264 return emptyString;
265 265
266 RELEASE_ASSERT(startPosition.compareTo(endPosition) <= 0); 266 CHECK_LE(startPosition.compareTo(endPosition), 0);
267 267
268 bool collapsed = startPosition == endPosition; 268 bool collapsed = startPosition == endPosition;
269 if (collapsed) 269 if (collapsed)
270 return emptyString; 270 return emptyString;
271 Node* commonAncestor = 271 Node* commonAncestor =
272 Strategy::commonAncestor(*startPosition.computeContainerNode(), 272 Strategy::commonAncestor(*startPosition.computeContainerNode(),
273 *endPosition.computeContainerNode()); 273 *endPosition.computeContainerNode());
274 if (!commonAncestor) 274 if (!commonAncestor)
275 return emptyString; 275 return emptyString;
276 276
(...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
755 textNode->appendData(textNext->data()); 755 textNode->appendData(textNext->data());
756 if (textNext->parentNode()) // Might have been removed by mutation event. 756 if (textNext->parentNode()) // Might have been removed by mutation event.
757 textNext->remove(exceptionState); 757 textNext->remove(exceptionState);
758 } 758 }
759 759
760 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingStrategy>; 760 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingStrategy>;
761 template class CORE_TEMPLATE_EXPORT 761 template class CORE_TEMPLATE_EXPORT
762 CreateMarkupAlgorithm<EditingInFlatTreeStrategy>; 762 CreateMarkupAlgorithm<EditingInFlatTreeStrategy>;
763 763
764 } // namespace blink 764 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698