master: Add a folder stub for reverse-values-list

stassats via Sbcl-commits <[email protected]>
Newsgroups gmane.lisp.steel-bank.cvs
Message-ID <[email protected]>
The branch "master" has been updated in SBCL:
       via  6a371bf547f722e75c2f5e88ddcdf84d5c9858d9 (commit)
      from  0d87331ec9dff388e941646cb84605c749be765c (commit)

- Log -----------------------------------------------------------------
commit 6a371bf547f722e75c2f5e88ddcdf84d5c9858d9
Author: Stas Boukarev <[email protected]>
Date:   Mon Aug 24 02:07:29 2026 +0300

    Add a folder stub for reverse-values-list
    
    Reported by Andrew Wolven
---
 src/compiler/fndb.lisp | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/compiler/fndb.lisp b/src/compiler/fndb.lisp
index 39eb00b94..8c4626220 100644
--- a/src/compiler/fndb.lisp
+++ b/src/compiler/fndb.lisp
@@ -131,7 +131,11 @@
 ;;; represented by a call to VALUES.
 (defknown values (&rest t) * (movable flushable))
 (defknown values-list (list) * (movable foldable unsafely-flushable))
-(defknown reverse-values-list (list index) * (movable foldable unsafely-flushable))
+(defknown reverse-values-list ((read-only list) index) *
+    (movable foldable unsafely-flushable)
+  :folder (lambda (list length)
+            (aver (= (length list) length))
+            (values-list (reverse list))))
 
 ;;;; from the "Macros" chapter:
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
SBCL
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.