* support inline /* */ comments

This commit is contained in:
Garux 2021-10-07 22:14:50 +03:00
parent 93898d3990
commit f3a4877ce7

View File

@ -211,13 +211,13 @@ skipspace:
// /* */ comments
if ( script.it[0] == '/' && script.it[1] == '*' ) {
if ( !crossline ) {
Error( "Line %i is incomplete\nFile location be: %s\n", scriptline, g_strLoadedFileLocation );
}
script.it += 2;
while ( script.it[0] != '*' || script.it[1] != '/' )
{
if ( *script.it == '\n' ) {
if ( !crossline ) {
Error( "Line %i is incomplete\nFile location be: %s\n", scriptline, g_strLoadedFileLocation );
}
script.line++;
scriptline = script.line;
}