Add a build flag to enable ES6 class syntax. Also recognize keywords used in ES6 class syntax when this build flag is turned on.
Created attachment 245120 [details] Adds a build flag
Attachment 245120 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/parser/Keywords.table:13: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:16: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:33: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:34: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:79: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:80: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:81: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:82: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:84: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:85: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:87: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5] Total errors found: 12 in 17 files If any of these errors are false positives, please file a bug against check-webkit-style.
Created attachment 245121 [details] Fixed the build failure
Attachment 245121 [details] did not pass style-queue: ERROR: Source/JavaScriptCore/parser/Keywords.table:13: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:16: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:33: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/Keywords.table:34: Line contains tab character. [whitespace/tab] [5] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:79: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:80: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:81: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:82: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:84: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:85: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/JavaScriptCore/parser/ParserTokens.h:87: enum members should use InterCaps with an initial capital letter. [readability/enum_casing] [4] ERROR: Source/WebCore/ChangeLog:8: You should remove the 'No new tests' and either add and list tests, or explain why no new tests were possible. [changelog/nonewtests] [5] Total errors found: 12 in 17 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 245121 [details] Fixed the build failure View in context: https://bugs.webkit.org/attachment.cgi?id=245121&action=review I think we should rename ENABLE_CLASS_SYNTAX to ENABLE_ES6_CLASS_SYNTAX. Look into mac-wk2 build failure. r=me with suggested changes. > Source/JavaScriptCore/parser/Keywords.table:13 > +class CLASSTOKEN Change the tabs to spaces. > Source/JavaScriptCore/parser/Keywords.table:16 > +extends EXTENDS Ditto > Source/JavaScriptCore/parser/Keywords.table:34 > +static STATICTOKEN > +super SUPER Ditto
Committed r178954: <http://trac.webkit.org/changeset/178954>