Movatterモバイル変換


[0]ホーム

URL:


[Python-Dev] Generalised String Coercion

"Martin v. Löwis"martin at v.loewis.de
Mon Aug 8 23:42:01 CEST 2005


Phillip J. Eby wrote:> Actually, thinking about it some more, it seems to me it's actually more> like this:>>    sock.send( ("%d:%s," %> (len(data),data.decode('latin1'))).encode('latin1') )While this would work, it would still feel wrong: the binary dataare *not* latin1 (most likely), so declaring them to be latin1 wouldbe confusing. Perhaps a synonym '8bit' for latin1 could be introduced.Regards,Martin


More information about the Python-Devmailing list

[8]ページ先頭

©2009-2025 Movatter.jp