That's the only per-importer change required! The code we have been 
discussing appears in the base Importer class. i.finalize_ivars, also in 
the base class, will restore trailing newlines like this:

>
>     v._bodyString = ''.join[z+'\n' for z in v._import_lines]
>
> This is itself simpler than the existing code.
>
> May I suggest:

 
v._bodyString = '\n'.join(v._import_lines) + '\n'

This uses the C-code of Python and contains only one string addition.

Reinhard


-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.

Reply via email to