Skip to content
Snippets Groups Projects
  • Tom Tromey's avatar
    688e7a53
    re PR preprocessor/33415 (Can't compile .cpp file with UTF-8 BOM.) · 688e7a53
    Tom Tromey authored
    libcpp
    	PR libcpp/33415:
    	* charset.c (_cpp_convert_input): Add buffer_start argument.
    	Ignore UTF-8 BOM if seen.
    	* internal.h (_cpp_convert_input): Add argument.
    	* files.c (struct _cpp_file) <buffer_start>: New field.
    	(destroy_cpp_file): Free buffer_start, not buffer.
    	(_cpp_pop_file_buffer): Likewise.
    	(read_file_guts): Update.
    gcc/testsuite
    	PR libcpp/33415:
    	* gcc.dg/cpp/pr33415.c: New file.
    
    From-SVN: r134507
    688e7a53
    History
    re PR preprocessor/33415 (Can't compile .cpp file with UTF-8 BOM.)
    Tom Tromey authored
    libcpp
    	PR libcpp/33415:
    	* charset.c (_cpp_convert_input): Add buffer_start argument.
    	Ignore UTF-8 BOM if seen.
    	* internal.h (_cpp_convert_input): Add argument.
    	* files.c (struct _cpp_file) <buffer_start>: New field.
    	(destroy_cpp_file): Free buffer_start, not buffer.
    	(_cpp_pop_file_buffer): Likewise.
    	(read_file_guts): Update.
    gcc/testsuite
    	PR libcpp/33415:
    	* gcc.dg/cpp/pr33415.c: New file.
    
    From-SVN: r134507