homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author michael-lazar
Recipients barry, manu-beffara, michael-lazar, petri.lehtinen, r.david.murray
Date 2016年07月13日.01:22:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1468372934.48.0.701508068184.issue14977@psf.upfronthosting.co.za>
In-reply-to
Content
I can certainly do that. Although in addition to adding a keyword argument, we would also have to change the return signature to switch between modes like this:
 if lineno is None:
 return caps
 else:
 return caps, lineno
Overall I'm not a fan of this technique and would like to avoid it if possible. The problem is that we have to keep track of the current line between successive calls to readmailcapfile(). An alternative would be to go back to using lineno as a generator. This is close to what I had in the initial patch.
 lineno = itertools.count()
 caps = readmailcapfile(fp, lineno=lineno)
 caps = readmailcapfile(fp2, lineno=lineno)
 caps = readmailcapfile(fp3, lineno=lineno)
 ...etc
Happy to hear any insights you have on this.
History
Date User Action Args
2016年07月13日 01:22:14michael-lazarsetrecipients: + michael-lazar, barry, r.david.murray, petri.lehtinen, manu-beffara
2016年07月13日 01:22:14michael-lazarsetmessageid: <1468372934.48.0.701508068184.issue14977@psf.upfronthosting.co.za>
2016年07月13日 01:22:14michael-lazarlinkissue14977 messages
2016年07月13日 01:22:13michael-lazarcreate

AltStyle によって変換されたページ (->オリジナル) /