OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> | 2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> |
3 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. | 3 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. |
4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 evaluationContext.size = nodes.size(); | 143 evaluationContext.size = nodes.size(); |
144 evaluationContext.position = j + 1; | 144 evaluationContext.position = j + 1; |
145 if (predicate->evaluate()) | 145 if (predicate->evaluate()) |
146 newNodes->append(node); | 146 newNodes->append(node); |
147 } | 147 } |
148 | 148 |
149 nodes.swap(*newNodes); | 149 nodes.swap(*newNodes); |
150 } | 150 } |
151 } | 151 } |
152 | 152 |
153 #if !ASSERT_DISABLED | 153 #if ASSERT_ENABLED |
154 static inline Node::NodeType primaryNodeType(Step::Axis axis) | 154 static inline Node::NodeType primaryNodeType(Step::Axis axis) |
155 { | 155 { |
156 switch (axis) { | 156 switch (axis) { |
157 case Step::AttributeAxis: | 157 case Step::AttributeAxis: |
158 return Node::ATTRIBUTE_NODE; | 158 return Node::ATTRIBUTE_NODE; |
159 default: | 159 default: |
160 return Node::ELEMENT_NODE; | 160 return Node::ELEMENT_NODE; |
161 } | 161 } |
162 } | 162 } |
163 #endif | 163 #endif |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
403 nodes.markSorted(false); | 403 nodes.markSorted(false); |
404 return; | 404 return; |
405 } | 405 } |
406 } | 406 } |
407 ASSERT_NOT_REACHED(); | 407 ASSERT_NOT_REACHED(); |
408 } | 408 } |
409 | 409 |
410 | 410 |
411 } | 411 } |
412 } | 412 } |
OLD | NEW |