2010/05/07

Fixed Memo on Narwhal

I changed the following:

Customization

  • BUF_LEN in c_generator.c was changed to 4096 because stack overflow occurs on generating parser.
  • Preprocessor condition on swprintf's parameter was added to generated parser because the warning 4706 occurred and it causes the access violation at runtime.

Fixed Bugs?

  • It is necessary to escape double quote (") in print_escape function because it causes such compile errors as C2308, C2001, and C1057 during compiling the generated parser, if grammar includes double quote.
  • Generated str_dup and wcs_dup functions became 'static' because compile errors on multiple definition occurred during compiling the generated parser if there are two or more parsers in a program.
  • Order of the following expressions in c_generator.c was swapped because the warning 4702 occurred when compiling the generated parser.
    ib->buf_size -= INPUT_BUFFER_SIZE_INCREMENT;\n"
    return WEOF;\n"
  • Type of 'eol_pos' of find_line_endings generated by print_utility_source function at c_generator.c was fixed to int because the warning 4244 occurred during compiling the generated parser.
  • The local variable 'n' of find_line function generated by the print_utility_source function became initialized as -1 because the warning 4701 occurred during compiling the generated parser.

Note

  • I set compiler option to suppress the warning 4706 and 4100 during compiling the generated parser.

No comments:

How to set parameters to debugging program on Visual Studio 2019 with CMake

Solution: MSDN Sometimes the "Debug and Launch Settings for CMake" bottun is disabled. In this case, change to the target view. ...