Hello,

This is in the new encode once only stream code, so I ask here before
making a change, I could be missing something, Gavin you probably
will have comments/advices.

I do not think that it is a good thing to set OUTPUT_PERL_ENCODING to an
empty string to prevent _stream_encode to encode if a character string
is wanted, as is done in test_utils.pl in convert_to_plaintext if
convert() is called on a Plaintext converter (same for Info).  I think
that it should be another information, set in the converter if called
through convert.  For two reasons, first OUTPUT_PERL_ENCODING
information could still be needed later on when outputting to a file
(this is the case in test_utils.pl) and second because convert() should
always return a character strings independentely of any customization
information.

A more minor issue, if $self->{'encoding_object'} is not set, it will
be retested for 'output_perl_encoding' value each time _stream_encode is
called.  Maybe it would be better to set it to 0 or to undef and test if
(!exists($self->{'encoding_object'})).

If my analysis is ok, should I try to propose some change, or not?

-- 
Pat

Reply via email to