R. David Murray <rdmur...@bitdance.com> added the comment:

I think I can see how it would cause confusion, and in general it shouldn't be 
necessary to use real tabs in a doctest.  So as you say the output should be 
fixed to match.

However, I don't think the patch is quite correct.  It looks to me like the 
expandtabs call should be made unconditionally on the output string just like 
it is on the string pulled from the file.  The reason is that the tabs in the 
output should be expanded relative to the start of the output line.  The 
indentation is meaningless in that context.  The way you did it, the output in 
your test appears to be indented incorrectly.  If the expandtabs were done on 
the raw output string, it would be indented eight spaces from the start of the 
test indent, and that would look correct.

Your change of 'iff' to 'if' is also most likely incorrect.  I'm pretty sure 
that 'iff' is intentional (it is an abbreviation for "if and only if".)

----------
assignee:  -> r.david.murray
resolution:  -> accepted
stage:  -> patch review

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue7583>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to