def read(self, n=-<NUM_LIT:1>):
buf = '<STR_LIT>'<EOL>if n is None:<EOL><INDENT>n = -<NUM_LIT:1><EOL><DEDENT>while True:<EOL><INDENT>if n < <NUM_LIT:0>:<EOL><INDENT>data = self.read1(n)<EOL><DEDENT>elif n > len(buf):<EOL><INDENT>data = self.read1(n - len(buf))<EOL><DEDENT>else:<EOL><INDENT>return buf<EOL><DEDENT>if len(data) == <NUM_LIT:0>:<EOL><INDENT>return buf<EOL><DEDENT>buf += data<EOL><DEDENT>
Read and return up to n bytes.
        If the argument is omitted, None, or negative, data is read and returned until EOF is reached..