[m-rev.] diff: clarify the behaviour of io.read_bitmap/[67]

Julien Fischer jfischer at opturion.com
Tue Oct 9 14:07:08 AEDT 2018


Clarify the behaviour of io.read_bitmap/[67].

library/io.m:
     Mention that the above predicates will throw an exception
     if the bitmap contains a partial final byte.

Julien.

diff --git a/library/io.m b/library/io.m
index 17329d4..1e0853b 100644
--- a/library/io.m
+++ b/library/io.m
@@ -877,6 +877,7 @@
      % Return the number of bytes read. On end-of-file, the number of
      % bytes read will be less than the size of the bitmap, and
      % the result will be `ok'.
+    % Throws an exception if the bitmap has a partial final byte.
      %
  :- pred read_bitmap(bitmap::bitmap_di, bitmap::bitmap_uo,
      int::out, io.res::out, io::di, io::uo) is det.


More information about the reviews mailing list