Discussion:
Cannot submit a ticket to trac - using the mailling list (proposed small optimization in output.py)
Guillaume P.
2012-04-10 20:49:14 UTC
Permalink
Hello,

I have seen this in genshi/output.py, and thought it could be
appropriate to report an enhancement to the code.

In this function:

{{{
def encode(iterator, method='xml', encoding=None, out=None):
[...]
if out is None:
return _encode(''.join(list(iterator)))
}}}

Should not this line be instead:

{{{
if out is None:
return _encode(''.join(iterator))
}}}

in order to save some memory and CPU cycles?

What do you think?

Thanks,


PS: I have been trying to submit a ticket in the trac system, but it
gets rejected because of spam suspicion...
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To post to this group, send email to ***@googlegroups.com.
To unsubscribe from this group, send email to genshi+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/genshi?hl=en.
Loading...