[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #6 from jcavalla at postini dot com  2007-04-20 22:59 ---
I ran additional tests just to make sure that the shift state was valid across
calls, even though partial is not returned when a chunk ends in a partial
encoding sequence.  I split several 2,3, and 4 byte UTF character sequences
across two calls to the codecvt in() method.  Each time, the sequence was
correctly widened into 1 UTF-32 character code.  Thus, the shift state appears
to be OK.  Just the return value of 'ok' is incorrect.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643



[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #5 from jcavalla at postini dot com  2007-04-20 22:37 ---
1.  Please note that 'g++' was used to compile, not 'gcc' as stated below. 
Sorry.

2.  I marked this bug 'major' instead or 'normal' because callers will not be
able to determine whether or not they need to supply more input to complete a
sequence.
If in a read/convert type loop with preserved shift state across convert calls,
this may not matter.  I will run such a test and post the results.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643



[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #4 from jcavalla at postini dot com  2007-04-20 22:32 ---
Created an attachment (id=13398)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13398&action=view)
Test results


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643



[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #3 from jcavalla at postini dot com  2007-04-20 22:31 ---
Created an attachment (id=13397)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13397&action=view)
Preprocessed intermediate file


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643



[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #2 from jcavalla at postini dot com  2007-04-20 22:31 ---
Created an attachment (id=13396)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13396&action=view)
Original test case source file


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643



[Bug libstdc++/31643] Codecvt facets with UTF-8 encoding fail to recognize partial encoding sequences

2007-04-20 Thread jcavalla at postini dot com


--- Comment #1 from jcavalla at postini dot com  2007-04-20 22:30 ---
Created an attachment (id=13395)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13395&action=view)
Verbose compilation output

Produced with:

g++ -v --save-temps -Wall -ansi -pedantic -g -o localetest localetest.cxx


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31643