Skip to content

Commit

Permalink
Fixed read-file-into-string bug.
Browse files Browse the repository at this point in the history
Quoting :doc note-8-1:

  A bug has been fixed in the logical definition of the function,
  read-file-into-string2, which supports the macro,
  [read-file-into-string].  Thanks to Keshav Kini for finding this
  bug and to Mihir Mehta for a query leading to Keshav's
  investigation.
  • Loading branch information
MattKaufmann committed Jul 14, 2018
1 parent 412d960 commit 8388ac1
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 6 deletions.
5 changes: 5 additions & 0 deletions books/system/doc/acl2-doc.lisp
Expand Up @@ -80621,6 +80621,11 @@ it."
(MV X X) is 1 but the actual number of return values is 2.'' This has been
fixed. Thanks to Eric Smith for bringing this problem to our attention.</p>

<p>A bug has been fixed in the logical definition of the function,
@('read-file-into-string2'), which supports the macro, @(tsee
read-file-into-string). Thanks to Keshav Kini for finding this bug and to
Mihir Mehta for a query leading to Keshav's investigation.</p>

<h3>Changes at the System Level</h3>

<p>Fixed the use of `@('<a href='URL'>...</a>')' so that if @('URL') has the
Expand Down
12 changes: 9 additions & 3 deletions doc.lisp
Expand Up @@ -79104,6 +79104,12 @@ Bug Fixes
2.'' This has been fixed. Thanks to Eric Smith for bringing this
problem to our attention.

A bug has been fixed in the logical definition of the function,
read-file-into-string2, which supports the macro,
[read-file-into-string]. Thanks to Keshav Kini for finding this
bug and to Mihir Mehta for a query leading to Keshav's
investigation.


Changes at the System Level

Expand Down Expand Up @@ -90610,10 +90616,10 @@ Subtopics
(mv nil val state)))))))
(mv erp
(and (stringp val)
(<= start (len val))
(<= start (length val))
(subseq val start
(if bytes (min (+ start bytes) (len val))
(len val)))))))
(if bytes (min (+ start bytes) (length val))
(length val)))))))
(declare (ignore erp))
val)))

Expand Down
6 changes: 3 additions & 3 deletions other-events.lisp
Expand Up @@ -30167,13 +30167,13 @@
; If the following conjunct is false, then raw Lisp would cause an error; so
; there is no harm in adding it (and, it helps with guard verification).

(<= start (len val))
(<= start (length val))
(subseq val
start
(if bytes
(min (+ start bytes)
(len val))
(len val)))))))
(length val))
(length val)))))))
(declare (ignore erp))
val)))
)
Expand Down

0 comments on commit 8388ac1

Please sign in to comment.