1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-09 14:21:03 +03:00

Small performance improvement and size reduction by recognizing that no

SQL keywords have less than 2 characters.

FossilOrigin-Name: 6b3d25b7982623ab4b25161aff9ab44778e136069043ab425543597c42c98ae5
This commit is contained in:
drh
2023-06-19 20:54:49 +00:00
parent 1be61ad278
commit 1e24dc987a
4 changed files with 28 additions and 28 deletions

View File

@@ -505,7 +505,8 @@ int sqlite3GetToken(const unsigned char *z, int *tokenType){
return i;
}
case CC_KYWD0: {
for(i=1; aiClass[z[i]]<=CC_KYWD; i++){}
if( aiClass[z[1]]>CC_KYWD ){ i = 1; break; }
for(i=2; aiClass[z[i]]<=CC_KYWD; i++){}
if( IdChar(z[i]) ){
/* This token started out using characters that can appear in keywords,
** but z[i] is a character not allowed within keywords, so this must