libgraphqlparser icon indicating copy to clipboard operation
libgraphqlparser copied to clipboard

Fix unsigned int warnings

Open jeroen opened this issue 3 years ago • 1 comments

This fixes the following warnings (using -Wall -pedantic with clang 15)

g++ -std=gnu++11 -I/usr/local/include    -fvisibility=hidden -fpic  -Wall -pedantic -c libgraphqlparser/lexer.cpp -o libgraphqlparser/lexer.o

lexer.lpp: In function ‘int yylex(yystype*, yy::location*, yyscan_t)’:
lexer.lpp:95:24: warning: format ‘%x’ expects argument of type ‘unsigned int*’, but argument 3 has type ‘int*’ [-Wformat=]

lexer.lpp: In function ‘bool is_all_whitespace(const std::string&)’:
lexer.lpp:274:40: warning: comparison of integer expressions of different signedness: ‘int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]

lexer.lpp: In function ‘std::string clean_up_block_string(const std::string&)’:
lexer.lpp:287:16: warning: comparison of integer expressions of different signedness: ‘const int’ and ‘std::__cxx11::basic_string<char>::size_type’ {aka ‘long unsigned int’} [-Wsign-compare]

jeroen avatar Sep 26 '22 07:09 jeroen

CLA Signed

The committers listed above are authorized under a signed CLA.

  • :white_check_mark: login: jeroen / name: Jeroen Ooms (3fe561736dffcdee2f8c8d17e10a0f9b0f3e656a)