Skip to content

Commit

Permalink
fix compile warning originating in cpp skeleton
Browse files Browse the repository at this point in the history
`gcount()` is of type `streamsize` which has a system-dependent size with at least `int`. Because of the `int max_size` limit no bigger value will be returned, the explicit cast fixes warnings from compilers/static analyzers.
  • Loading branch information
GitMensch authored Jun 22, 2021
1 parent 7b073fd commit b198864
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cpp-flex.skl
Original file line number Diff line number Diff line change
Expand Up @@ -2390,7 +2390,7 @@ int yyFlexLexer::LexerInput( char* buf, int max_size )
if ( yyin.bad() ) {
return -1;
} else {
return yyin.gcount();
return (int)yyin.gcount();
}
#endif
}
Expand Down

0 comments on commit b198864

Please sign in to comment.