Author takluyver
Recipients takluyver
Date 2012-10-28.12:43:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
At least in CPython, format strings can be given as bytes, as an alternative to str. E.g.

>>> struct.unpack(b'>hhl', b'\x00\x01\x00\x02\x00\x00\x00\x03')
(1, 2, 3)

Looking at the source code [1], this appears to be consciously accounted for. But it doesn't seem to be mentioned in the documentation. I think the docs should either say it's a possibility, or warn that it's an implementation detail.

Date User Action Args
2012-10-28 12:43:42takluyversetrecipients: + takluyver
2012-10-28 12:43:42takluyversetmessageid: <>
2012-10-28 12:43:42takluyverlinkissue16349 messages
2012-10-28 12:43:42takluyvercreate