Page Speed Optimization Libraries
1.13.35.1
|
Classes | |
class | Iterator |
Public Types | |
enum | Type { kNull, kTrue, kFalse, kBreak, kCase, kCatch, kConst, kDefault, kFinally, kFor, kInstanceof, kNew, kVar, kContinue, kFunction, kReturn, kVoid, kDelete, kIf, kThis, kDo, kWhile, kElse, kIn, kSwitch, kThrow, kTry, kTypeof, kWith, kDebugger, kClass, kEnum, kExport, kExtends, kImport, kSuper, kImplements, kInterface, kLet, kPackage, kPrivate, kProtected, kPublic, kStatic, kYield, kNotAKeyword, kComment, kWhitespace, kLineSeparator, kSemiInsert, kRegex, kStringLiteral, kNumber, kOperator, kIdentifier, kEndOfInput, kError } |
enum | Flag { kNone, kIsValue, kIsReservedNonStrict, kIsReservedStrict, kCanPrecedeRegEx } |
Static Public Member Functions | |
static bool | IsAKeyword (Type type) |
static bool | CanKeywordPrecedeRegEx (const StringPiece &name) |
static Type | Lookup (const StringPiece &name, Flag *flag) |
Friends | |
class | net_instaweb::JsLexer |
|
static |
Returns true if name is a javascript keyword that can precede a regular expression. Keywords such as 'return' and 'throw' can precede a regex '/' but keywords such as 'while' cannot.
Finds a Keyword based on a keyword string. If not found, returns kNotAKeyword. Otherwise, this always returns a Type for which IsAKeyword is true.
|
friend |