1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-30 19:03:16 +03:00

Fix the parsing of C-style comments in Lemon, as reported by

[forum:/forumpost/b6edc69548|forum post b6edc69548].  This has no affect
on SQLite itself.

FossilOrigin-Name: 201569e09b000919ccb463bd581fb2ecd5320e7f584fdb1bc2aaba111061d5c3
This commit is contained in:
drh
2022-04-07 14:13:32 +00:00
parent a744167956
commit db08a6d13c
3 changed files with 8 additions and 7 deletions

View File

@ -3015,6 +3015,7 @@ void Parse(struct lemon *gp)
}
if( c=='/' && cp[1]=='*' ){ /* Skip C style comments */
cp+=2;
if( (*cp)=='/' ) cp++;
while( (c= *cp)!=0 && (c!='/' || cp[-1]!='*') ){
if( c=='\n' ) lineno++;
cp++;