mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
LibSQL: Lex string and blob literals
Blob literals are the same as string literals except prefixed with an 'x' or 'X'.
This commit is contained in:
parent
730fbfb31e
commit
570aa57df3
Notes:
sideshowbarker
2024-07-18 19:17:30 +09:00
Author: https://github.com/trflynn89
Commit: 570aa57df3
Pull-request: https://github.com/SerenityOS/serenity/pull/6538
Reviewed-by: https://github.com/awesomekling
3 changed files with 61 additions and 7 deletions
|
@ -182,6 +182,8 @@ namespace SQL {
|
|||
__ENUMERATE_SQL_TOKEN("WITHOUT", Without, Keyword) \
|
||||
__ENUMERATE_SQL_TOKEN("_identifier_", Identifier, Identifier) \
|
||||
__ENUMERATE_SQL_TOKEN("_numeric_", NumericLiteral, Number) \
|
||||
__ENUMERATE_SQL_TOKEN("_string_", StringLiteral, String) \
|
||||
__ENUMERATE_SQL_TOKEN("_blob_", BlobLiteral, Blob) \
|
||||
__ENUMERATE_SQL_TOKEN("_eof_", Eof, Invalid) \
|
||||
__ENUMERATE_SQL_TOKEN("_invalid_", Invalid, Invalid) \
|
||||
__ENUMERATE_SQL_TOKEN("&", Ampersand, Operator) \
|
||||
|
@ -221,6 +223,8 @@ enum class TokenCategory {
|
|||
Keyword,
|
||||
Identifier,
|
||||
Number,
|
||||
String,
|
||||
Blob,
|
||||
Operator,
|
||||
Punctuation,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue