Skip to content

Commit 30025c7

Browse files
committed
Improve docstring.
1 parent ed40c67 commit 30025c7

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

msgpack/_msgpack.pyx

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -529,8 +529,7 @@ cdef class Unpacker(object):
529529
If write_bytes is not None, it will be called with parts of the raw
530530
message as it is unpacked.
531531
532-
When there are not enough bytes for unpacking, `unpack()` raises
533-
`OutOfData` Exception.
532+
Raises `OutOfData` when there are no more bytes to unpack.
534533
"""
535534
return self._unpack(template_construct, write_bytes)
536535

@@ -541,26 +540,23 @@ cdef class Unpacker(object):
541540
If write_bytes is not None, it will be called with parts of the raw
542541
message as it is unpacked.
543542
544-
When there are not enough bytes for unpacking, `unpack()` raises
545-
`OutOfData` Exception.
543+
Raises `OutOfData` when there are no more bytes to unpack.
546544
"""
547545
return self._unpack(template_skip, write_bytes)
548546

549547
def read_array_header(self, object write_bytes=None):
550548
"""assuming the next object is an array, return its size n, such that
551549
the next n unpack() calls will iterate over its contents.
552550
553-
When there are not enough bytes for unpacking, `unpack()` raises
554-
`OutOfData` Exception.
551+
Raises `OutOfData` when there are no more bytes to unpack.
555552
"""
556553
return self._unpack(read_array_header, write_bytes)
557554

558555
def read_map_header(self, object write_bytes=None):
559556
"""assuming the next object is a map, return its size n, such that the
560557
next n * 2 unpack() calls will iterate over its key-value pairs.
561558
562-
When there are not enough bytes for unpacking, `unpack()` raises
563-
`OutOfData` Exception.
559+
Raises `OutOfData` when there are no more bytes to unpack.
564560
"""
565561
return self._unpack(read_map_header, write_bytes)
566562

0 commit comments

Comments
 (0)