|
46 | 46 | var PR_keywords = {}; |
47 | 47 | /** initialize the keyword list for our target languages. */ |
48 | 48 | (function () { |
49 | | - var CPP_KEYWORDS = ( |
50 | | - "bool break case catch char class const const_cast continue default " + |
51 | | - "delete deprecated dllexport dllimport do double dynamic_cast else enum " + |
52 | | - "explicit extern false float for friend goto if inline int long mutable " + |
53 | | - "naked namespace new noinline noreturn nothrow novtable operator private " + |
54 | | - "property protected public register reinterpret_cast return selectany " + |
55 | | - "short signed sizeof static static_cast struct switch template this " + |
56 | | - "thread throw true try typedef typeid typename union unsigned using " + |
57 | | - "declaration, using directive uuid virtual void volatile while typeof"); |
58 | | - var JAVA_KEYWORDS = ( |
59 | | - "abstract default goto package synchronized boolean do if private this " + |
60 | | - "break double implements protected throw byte else import public throws " + |
61 | | - "case enum instanceof return transient catch extends int short try char " + |
62 | | - "final interface static void class finally long strictfp volatile const " + |
63 | | - "float native super while continue for new switch"); |
64 | | - var PYTHON_KEYWORDS = ( |
65 | | - "and assert break class continue def del elif else except exec finally " + |
66 | | - "for from global if import in is lambda not or pass print raise return " + |
67 | | - "try while yield False True None"); |
68 | | - var JSCRIPT_KEYWORDS = ( |
69 | | - "abstract boolean break byte case catch char class const continue " + |
70 | | - "debugger default delete do double else enum export extends false final " + |
71 | | - "finally float for function goto if implements import in instanceof int " + |
72 | | - "interface long native new null package private protected public return " + |
73 | | - "short static super switch synchronized this throw throws transient " + |
74 | | - "true try typeof var void volatile while with NaN Infinity"); |
75 | | - var PERL_KEYWORDS = ( |
76 | | - "foreach require sub unless until use elsif BEGIN END"); |
77 | | - var SH_KEYWORDS = ( |
78 | | - "if then do done else fi end"); |
79 | | - var RUBY_KEYWORDS = ( |
80 | | - "if then elsif else end begin do rescue ensure while for class module " + |
81 | | - "def yield raise until unless and or not when case super undef break " + |
82 | | - "next redo retry in return alias defined"); |
83 | | - var KEYWORDS = [CPP_KEYWORDS, JAVA_KEYWORDS, JSCRIPT_KEYWORDS, PERL_KEYWORDS, |
84 | | - PYTHON_KEYWORDS, RUBY_KEYWORDS, SH_KEYWORDS]; |
| 49 | + var CPP_KEYWORDS = "abstract bool break case catch char class const " + |
| 50 | + "const_cast continue default delete deprecated dllexport dllimport do " + |
| 51 | + "double dynamic_cast else enum explicit extern false float for friend " + |
| 52 | + "goto if inline int long mutable naked namespace new noinline noreturn " + |
| 53 | + "nothrow novtable operator private property protected public register " + |
| 54 | + "reinterpret_cast return selectany short signed sizeof static " + |
| 55 | + "static_cast struct switch template this thread throw true try typedef " + |
| 56 | + "typeid typename union unsigned using declaration, directive uuid " + |
| 57 | + "virtual void volatile while typeof"; |
| 58 | + var CSHARP_KEYWORDS = "as base by byte checked decimal delegate descending " + |
| 59 | + "event finally fixed foreach from group implicit in interface internal " + |
| 60 | + "into is lock null object out override orderby params readonly ref sbyte " + |
| 61 | + "sealed stackalloc string select uint ulong unchecked unsafe ushort var"; |
| 62 | + var JAVA_KEYWORDS = "package synchronized boolean implements import throws " + |
| 63 | + "instanceof transient extends final strictfp native super"; |
| 64 | + var JSCRIPT_KEYWORDS = "debugger export function with NaN Infinity"; |
| 65 | + var PERL_KEYWORDS = "require sub unless until use elsif BEGIN END"; |
| 66 | + var PYTHON_KEYWORDS = "and assert def del elif except exec global lambda " + |
| 67 | + "not or pass print raise yield False True None"; |
| 68 | + var RUBY_KEYWORDS = "then end begin rescue ensure module when undef next " + |
| 69 | + "redo retry alias defined"; |
| 70 | + var SH_KEYWORDS = "done fi"; |
| 71 | + |
| 72 | + var KEYWORDS = [CPP_KEYWORDS, CSHARP_KEYWORDS, JAVA_KEYWORDS, |
| 73 | + JSCRIPT_KEYWORDS, PERL_KEYWORDS, PYTHON_KEYWORDS, |
| 74 | + RUBY_KEYWORDS, SH_KEYWORDS]; |
85 | 75 | for (var k = 0; k < KEYWORDS.length; k++) { |
86 | 76 | var kw = KEYWORDS[k].split(' '); |
87 | 77 | for (var i = 0; i < kw.length; i++) { |
|
0 commit comments