201 | elif len(l) < 0x100000000L:
202 | - r = chr(254) + struct.pack("<I", len(l))
203 | + r = struct.pack("B", 254) + struct.pack("<I", len(l))
204 | else:
205 | - r = chr(255) + struct.pack("<Q", len(l))
206 | + r = struct.pack("B", 255) + struct.pack("<Q", len(l))
What about:
r = struct.pack("<BQ", 255, len(l))
etc?
Sure, this makes sense. I've tried to make the diff easier to read but I will address you nit, as it makes the code smaller and possibly easier to read.
Thanks, yes I agree with regard to keeping the minimum diff, but indeed it's better to do this small cleanup (which someone is bound to do later) at the same time.