Skip to content

Commit 18f42f7

Browse files
committed
Context: Updated contexts to contain 'BIT' data type.
Tools: Documented tags in ContextGenerator.
1 parent d888929 commit 18f42f7

File tree

7 files changed

+20
-19
lines changed

7 files changed

+20
-19
lines changed

src/Contexts/ContextMySql50000.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class ContextMySql50000 extends Context
3737
public static $KEYWORDS = array(
3838

3939
'DO' => 1, 'IO' => 1, 'NO' => 1, 'XA' => 1,
40-
'ANY' => 1, 'BDB' => 1, 'BIT' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1,
41-
'NDB' => 1, 'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
40+
'ANY' => 1, 'BDB' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1,
41+
'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
4242
'BOOL' => 1, 'BYTE' => 1, 'CODE' => 1, 'CUBE' => 1, 'DATA' => 1, 'FAST' => 1,
4343
'FILE' => 1, 'FULL' => 1, 'HASH' => 1, 'HELP' => 1, 'LAST' => 1, 'LOGS' => 1,
4444
'MODE' => 1, 'NAME' => 1, 'NEXT' => 1, 'NONE' => 1, 'OPEN' => 1, 'PAGE' => 1,
@@ -162,7 +162,7 @@ class ContextMySql50000 extends Context
162162
'DEFAULT CHARACTER SET' => 7,
163163
'WITH CONSISTENT SNAPSHOT' => 7,
164164

165-
'XML' => 9,
165+
'BIT' => 9, 'XML' => 9,
166166
'ENUM' => 9, 'JSON' => 9, 'TEXT' => 9,
167167
'ARRAY' => 9,
168168
'SERIAL' => 9,

src/Contexts/ContextMySql50100.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class ContextMySql50100 extends Context
3737
public static $KEYWORDS = array(
3838

3939
'AT' => 1, 'DO' => 1, 'IO' => 1, 'NO' => 1, 'XA' => 1,
40-
'ANY' => 1, 'BDB' => 1, 'BIT' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1,
41-
'NDB' => 1, 'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
40+
'ANY' => 1, 'BDB' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1,
41+
'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
4242
'BOOL' => 1, 'BYTE' => 1, 'CODE' => 1, 'CUBE' => 1, 'DATA' => 1, 'DISK' => 1,
4343
'ENDS' => 1, 'FAST' => 1, 'FILE' => 1, 'FULL' => 1, 'GOTO' => 1, 'HASH' => 1,
4444
'HELP' => 1, 'HOST' => 1, 'LAST' => 1, 'LESS' => 1, 'LIST' => 1, 'LOGS' => 1,
@@ -175,7 +175,7 @@ class ContextMySql50100 extends Context
175175
'DEFAULT CHARACTER SET' => 7,
176176
'WITH CONSISTENT SNAPSHOT' => 7,
177177

178-
'XML' => 9,
178+
'BIT' => 9, 'XML' => 9,
179179
'ENUM' => 9, 'JSON' => 9, 'TEXT' => 9,
180180
'ARRAY' => 9,
181181
'SERIAL' => 9,

src/Contexts/ContextMySql50500.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class ContextMySql50500 extends Context
3737
public static $KEYWORDS = array(
3838

3939
'AT' => 1, 'DO' => 1, 'IO' => 1, 'NO' => 1, 'XA' => 1,
40-
'ANY' => 1, 'BIT' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1,
41-
'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
40+
'ANY' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1, 'NEW' => 1,
41+
'ONE' => 1, 'ROW' => 1,
4242
'BOOL' => 1, 'BYTE' => 1, 'CODE' => 1, 'CUBE' => 1, 'DATA' => 1, 'DISK' => 1,
4343
'ENDS' => 1, 'FAST' => 1, 'FILE' => 1, 'FULL' => 1, 'HASH' => 1, 'HELP' => 1,
4444
'HOST' => 1, 'LAST' => 1, 'LESS' => 1, 'LIST' => 1, 'LOGS' => 1, 'MODE' => 1,
@@ -180,7 +180,7 @@ class ContextMySql50500 extends Context
180180
'DEFAULT CHARACTER SET' => 7,
181181
'WITH CONSISTENT SNAPSHOT' => 7,
182182

183-
'XML' => 9,
183+
'BIT' => 9, 'XML' => 9,
184184
'ENUM' => 9, 'JSON' => 9, 'TEXT' => 9,
185185
'ARRAY' => 9,
186186
'SERIAL' => 9,

src/Contexts/ContextMySql50600.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class ContextMySql50600 extends Context
3737
public static $KEYWORDS = array(
3838

3939
'AT' => 1, 'DO' => 1, 'IO' => 1, 'NO' => 1, 'XA' => 1,
40-
'ANY' => 1, 'BIT' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1,
41-
'NEW' => 1, 'ONE' => 1, 'ROW' => 1,
40+
'ANY' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1, 'NEW' => 1,
41+
'ONE' => 1, 'ROW' => 1,
4242
'BOOL' => 1, 'BYTE' => 1, 'CODE' => 1, 'CUBE' => 1, 'DATA' => 1, 'DISK' => 1,
4343
'ENDS' => 1, 'FAST' => 1, 'FILE' => 1, 'FULL' => 1, 'HASH' => 1, 'HELP' => 1,
4444
'HOST' => 1, 'LAST' => 1, 'LESS' => 1, 'LIST' => 1, 'LOGS' => 1, 'MODE' => 1,
@@ -186,7 +186,7 @@ class ContextMySql50600 extends Context
186186
'DEFAULT CHARACTER SET' => 7,
187187
'WITH CONSISTENT SNAPSHOT' => 7,
188188

189-
'XML' => 9,
189+
'BIT' => 9, 'XML' => 9,
190190
'ENUM' => 9, 'JSON' => 9, 'TEXT' => 9,
191191
'ARRAY' => 9,
192192
'SERIAL' => 9,

src/Contexts/ContextMySql50700.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class ContextMySql50700 extends Context
3737
public static $KEYWORDS = array(
3838

3939
'AT' => 1, 'DO' => 1, 'IO' => 1, 'NO' => 1, 'XA' => 1,
40-
'ANY' => 1, 'BIT' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1,
41-
'NEW' => 1, 'ONE' => 1, 'ROW' => 1, 'XID' => 1,
40+
'ANY' => 1, 'CPU' => 1, 'END' => 1, 'IPC' => 1, 'NDB' => 1, 'NEW' => 1,
41+
'ONE' => 1, 'ROW' => 1, 'XID' => 1,
4242
'BOOL' => 1, 'BYTE' => 1, 'CODE' => 1, 'CUBE' => 1, 'DATA' => 1, 'DISK' => 1,
4343
'ENDS' => 1, 'FAST' => 1, 'FILE' => 1, 'FULL' => 1, 'HASH' => 1, 'HELP' => 1,
4444
'HOST' => 1, 'LAST' => 1, 'LESS' => 1, 'LIST' => 1, 'LOGS' => 1, 'MODE' => 1,
@@ -193,7 +193,7 @@ class ContextMySql50700 extends Context
193193
'DEFAULT CHARACTER SET' => 7,
194194
'WITH CONSISTENT SNAPSHOT' => 7,
195195

196-
'XML' => 9,
196+
'BIT' => 9, 'XML' => 9,
197197
'ENUM' => 9, 'JSON' => 9, 'TEXT' => 9,
198198
'ARRAY' => 9,
199199
'SERIAL' => 9,

tools/ContextGenerator.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ class ContextGenerator
2222
* @var array
2323
*/
2424
public static $LABELS_FLAGS = array(
25-
'(R)' => 2,
26-
'(D)' => 8,
27-
'(K)' => 16,
28-
'(F)' => 32,
25+
'(R)' => 2, // reserved
26+
'(D)' => 8, // data type
27+
'(K)' => 16, // keyword
28+
'(F)' => 32, // function name
2929
);
3030

3131
/**

tools/contexts/_common.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
BIT (D)
12
AGAINST (F)
23
AND CHAIN
34
AND NO CHAIN

0 commit comments

Comments
 (0)