re PR preprocessor/33415 (Can't compile .cpp file with UTF-8 BOM.)
authorTom Tromey <tromey@redhat.com>
Mon, 21 Apr 2008 14:02:00 +0000 (14:02 +0000)
committerTom Tromey <tromey@gcc.gnu.org>
Mon, 21 Apr 2008 14:02:00 +0000 (14:02 +0000)
commit688e7a53446776e4d7b49472b06fec29ea69ff17
tree95c70d6534e91125519d9a8f2e7c2cf84de0c82b
parent009890be6c6e3f34630be0f086303d42c6aa867b
re PR preprocessor/33415 (Can't compile .cpp file with UTF-8 BOM.)

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
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/cpp/pr33415.c [new file with mode: 0644]
libcpp/ChangeLog
libcpp/charset.c
libcpp/files.c
libcpp/internal.h