1 Oct
2011
1 Oct
'11
6:13 p.m.
Hello, I honestly didn't know we exposed such semantics, and I'm wondering if the functionality is worth the astonishement:
"abc" in io.StringIO("abc\ndef\n") False "abc\n" in io.StringIO("abc\ndef\n") True
Basically, io.StringIO provides iteration (it yields lines of text) and containment is apparently inferred from that. Regards Antoine.