OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 | 74 |
75 template <typename NodeType> | 75 template <typename NodeType> |
76 NodeType* StaticNodeTypeList<NodeType>::item(unsigned index) const { | 76 NodeType* StaticNodeTypeList<NodeType>::item(unsigned index) const { |
77 if (index < m_nodes.size()) | 77 if (index < m_nodes.size()) |
78 return m_nodes[index].get(); | 78 return m_nodes[index].get(); |
79 return 0; | 79 return 0; |
80 } | 80 } |
81 | 81 |
82 template <typename NodeType> | 82 template <typename NodeType> |
83 void StaticNodeTypeList<NodeType>::trace(Visitor* visitor) { | 83 void StaticNodeTypeList<NodeType>::trace(Visitor* visitor) { |
84 traceImpl(visitor); | |
85 } | |
86 template <typename NodeType> | |
87 void StaticNodeTypeList<NodeType>::trace(InlinedGlobalMarkingVisitor visitor) { | |
88 traceImpl(visitor); | |
89 } | |
90 | |
91 template <typename NodeType> | |
92 template <typename VisitorDispatcher> | |
93 ALWAYS_INLINE void StaticNodeTypeList<NodeType>::traceImpl( | |
94 VisitorDispatcher visitor) { | |
95 visitor->trace(m_nodes); | 84 visitor->trace(m_nodes); |
96 NodeList::trace(visitor); | 85 NodeList::trace(visitor); |
97 } | 86 } |
98 | 87 |
99 } // namespace blink | 88 } // namespace blink |
100 | 89 |
101 #endif // StaticNodeList_h | 90 #endif // StaticNodeList_h |
OLD | NEW |