📝 fix some warnings.

This commit is contained in:
ValKmjolnir
2022-07-10 23:55:51 +08:00
parent bcdc55a652
commit 8cc69c709f
2 changed files with 5 additions and 2 deletions
+1 -1
View File
@@ -126,7 +126,7 @@ void nasal_parse::die(uint32_t line,std::string info,bool report_prev=false)
int col=(int)tokens[ptr].col-(int)tokens[ptr].str.length();
if(tokens[ptr].type==tok_str)
col-=2; // tok_str's str has no \"
if(report_prev && ptr-1>=0) // used to report lack of ',' ';'
if(report_prev && ptr) // used to report lack of ',' ';'
{
line=tokens[ptr-1].line;
col=tokens[ptr-1].col+1;