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

Side by Side Diff: Source/core/css/parser/CSSParserToken.h

Issue 1304623002: Make blink classes and structures in core/css fast-allocated (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Patch for landing (Fixed windows compile error) Created 5 years, 4 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
« no previous file with comments | « Source/core/css/parser/CSSParserString.h ('k') | Source/core/css/parser/CSSParserTokenRange.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CSSParserToken_h 5 #ifndef CSSParserToken_h
6 #define CSSParserToken_h 6 #define CSSParserToken_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/css/CSSPrimitiveValue.h" 9 #include "core/css/CSSPrimitiveValue.h"
10 #include "core/css/parser/CSSParserString.h" 10 #include "core/css/parser/CSSParserString.h"
11 #include "wtf/Allocator.h"
11 12
12 namespace blink { 13 namespace blink {
13 14
14 enum CSSParserTokenType { 15 enum CSSParserTokenType {
15 IdentToken = 0, 16 IdentToken = 0,
16 FunctionToken, 17 FunctionToken,
17 AtKeywordToken, 18 AtKeywordToken,
18 HashToken, 19 HashToken,
19 UrlToken, 20 UrlToken,
20 BadUrlToken, 21 BadUrlToken,
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 IntegerValueType, 58 IntegerValueType,
58 NumberValueType, 59 NumberValueType,
59 }; 60 };
60 61
61 enum HashTokenType { 62 enum HashTokenType {
62 HashTokenId, 63 HashTokenId,
63 HashTokenUnrestricted, 64 HashTokenUnrestricted,
64 }; 65 };
65 66
66 class CORE_EXPORT CSSParserToken { 67 class CORE_EXPORT CSSParserToken {
68 WTF_MAKE_FAST_ALLOCATED(CSSParserToken);
67 public: 69 public:
68 enum BlockType { 70 enum BlockType {
69 NotBlock, 71 NotBlock,
70 BlockStart, 72 BlockStart,
71 BlockEnd, 73 BlockEnd,
72 }; 74 };
73 75
74 CSSParserToken(CSSParserTokenType, BlockType = NotBlock); 76 CSSParserToken(CSSParserTokenType, BlockType = NotBlock);
75 CSSParserToken(CSSParserTokenType, CSSParserString, BlockType = NotBlock); 77 CSSParserToken(CSSParserTokenType, CSSParserString, BlockType = NotBlock);
76 78
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 UChar32 end; 140 UChar32 end;
139 } m_unicodeRange; 141 } m_unicodeRange;
140 }; 142 };
141 }; 143 };
142 144
143 } // namespace blink 145 } // namespace blink
144 146
145 namespace WTF { 147 namespace WTF {
146 template <> 148 template <>
147 struct IsTriviallyMoveAssignable<blink::CSSParserToken> { 149 struct IsTriviallyMoveAssignable<blink::CSSParserToken> {
150 STATIC_ONLY(IsTriviallyMoveAssignable);
148 static const bool value = true; 151 static const bool value = true;
149 }; 152 };
150 } 153 }
151 154
152 #endif // CSSSParserToken_h 155 #endif // CSSSParserToken_h
OLDNEW
« no previous file with comments | « Source/core/css/parser/CSSParserString.h ('k') | Source/core/css/parser/CSSParserTokenRange.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698