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

Unified Diff: third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py

Issue 2329463004: ABANDONED CL: Changes needed to make things compile after running rewrite_to_chrome_style tool. (Closed)
Patch Set: More fixes - things build fine at this point. Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py
diff --git a/third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py b/third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py
index d7e81d50e0128e8238a9878ebc50893fb9ecb430..ce9cb40bdb22df0bcfeb0e2c73efcf4fdf31f51d 100755
--- a/third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py
+++ b/third_party/WebKit/Source/build/scripts/make_css_tokenizer_codepoints.py
@@ -18,7 +18,7 @@ CPP_TEMPLATE = """
// Auto-generated by {module_pyname}
-const CSSTokenizer::CodePoint CSSTokenizer::codePoints[{array_size}] = {{
+const CSSTokenizer::CodePoint CSSTokenizer::kCodePoints[{array_size}] = {{
{token_lines}
}};
const unsigned codePointsNumber = {array_size};
@@ -26,30 +26,30 @@ const unsigned codePointsNumber = {array_size};
def token_type(i):
- codepoints = {'(': 'leftParenthesis',
- ')': 'rightParenthesis',
- '[': 'leftBracket',
- ']': 'rightBracket',
- '{': 'leftBrace',
- '}': 'rightBrace',
- '+': 'plusOrFullStop',
- '.': 'plusOrFullStop',
- '-': 'hyphenMinus',
- '*': 'asterisk',
- '<': 'lessThan',
- ',': 'comma',
- '/': 'solidus',
- '\\': 'reverseSolidus',
- ':': 'colon',
- ';': 'semiColon',
- '#': 'hash',
- '^': 'circumflexAccent',
- '$': 'dollarSign',
- '|': 'verticalLine',
- '~': 'tilde',
- '@': 'commercialAt',
- 'u': 'letterU',
- 'U': 'letterU',
+ codepoints = {'(': 'LeftParenthesis',
+ ')': 'RightParenthesis',
+ '[': 'LeftBracket',
+ ']': 'RightBracket',
+ '{': 'LeftBrace',
+ '}': 'RightBrace',
+ '+': 'PlusOrFullStop',
+ '.': 'PlusOrFullStop',
+ '-': 'HyphenMinus',
+ '*': 'Asterisk',
+ '<': 'LessThan',
+ ',': 'Comma',
+ '/': 'Solidus',
+ '\\': 'ReverseSolidus',
+ ':': 'Colon',
+ ';': 'SemiColon',
+ '#': 'Hash',
+ '^': 'CircumflexAccent',
+ '$': 'DollarSign',
+ '|': 'VerticalLine',
+ '~': 'Tilde',
+ '@': 'CommercialAt',
+ 'u': 'LetterU',
+ 'U': 'LetterU',
}
c = chr(i)
if c in codepoints:
@@ -57,15 +57,15 @@ def token_type(i):
whitespace = '\n\r\t\f '
quotes = '"\''
if c in whitespace:
- return 'whiteSpace'
+ return 'WhiteSpace'
if c.isdigit():
- return 'asciiDigit'
+ return 'AsciiDigit'
if c.isalpha() or c == '_':
- return 'nameStart'
+ return 'NameStart'
if c in quotes:
- return 'stringStart'
+ return 'StringStart'
if i == 0:
- return 'endOfFile'
+ return 'EndOfFile'
class MakeCSSTokenizerCodePointsWriter(in_generator.Writer):

Powered by Google App Engine
This is Rietveld 408576698