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

Side by Side Diff: third_party/WebKit/Source/core/xml/XPathEvaluator.cpp

Issue 2701993002: DO NOT COMMIT: Results of running new (proposed) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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 2005 Frerich Raabe <raabe@kde.org> 2 * Copyright 2005 Frerich Raabe <raabe@kde.org>
3 * Copyright (C) 2006 Apple Computer, Inc. 3 * Copyright (C) 2006 Apple Computer, Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 } 51 }
52 52
53 XPathResult* XPathEvaluator::evaluate(const String& expression, 53 XPathResult* XPathEvaluator::evaluate(const String& expression,
54 Node* contextNode, 54 Node* contextNode,
55 XPathNSResolver* resolver, 55 XPathNSResolver* resolver,
56 unsigned short type, 56 unsigned short type,
57 const ScriptValue&, 57 const ScriptValue&,
58 ExceptionState& exceptionState) { 58 ExceptionState& exceptionState) {
59 if (!isValidContextNode(contextNode)) { 59 if (!isValidContextNode(contextNode)) {
60 exceptionState.throwDOMException( 60 exceptionState.throwDOMException(
61 NotSupportedError, "The node provided is '" + contextNode->nodeName() + 61 NotSupportedError,
62 "', which is not a valid context node type."); 62 "The node provided is '" + contextNode->nodeName() +
63 "', which is not a valid context node type.");
63 return nullptr; 64 return nullptr;
64 } 65 }
65 66
66 XPathExpression* expr = 67 XPathExpression* expr =
67 createExpression(expression, resolver, exceptionState); 68 createExpression(expression, resolver, exceptionState);
68 if (exceptionState.hadException()) 69 if (exceptionState.hadException())
69 return nullptr; 70 return nullptr;
70 71
71 return expr->evaluate(contextNode, type, ScriptValue(), exceptionState); 72 return expr->evaluate(contextNode, type, ScriptValue(), exceptionState);
72 } 73 }
73 74
74 } // namespace blink 75 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/workers/Worklet.cpp ('k') | third_party/WebKit/Source/core/xml/XPathExpression.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698