~ chicken-core (chicken-5) d98b153c34df3f44df28c1454bc51f6c5004caf9


commit d98b153c34df3f44df28c1454bc51f6c5004caf9
Author:     Evan Hanson <evhan@foldling.org>
AuthorDate: Sun Sep 10 13:02:11 2017 +1200
Commit:     Peter Bex <peter@more-magic.net>
CommitDate: Sun Sep 10 12:31:00 2017 +0200

    Remove the `any?` procedure
    
    Signed-off-by: Peter Bex <peter@more-magic.net>

diff --git a/c-platform.scm b/c-platform.scm
index 3cbf9747..b01b6edb 100644
--- a/c-platform.scm
+++ b/c-platform.scm
@@ -208,7 +208,7 @@
     chicken.data-structures#o
     chicken.string#substring-index chicken.string#substring-index-ci
     chicken.string#substring=? chicken.string#substring-ci=?
-    chicken.data-structures#any? chicken.data-structures#atom?
+    chicken.data-structures#atom?
     chicken.data-structures#alist-ref chicken.data-structures#rassoc
     chicken.io#read-string chicken.format#format
     chicken.format#printf chicken.format#sprintf chicken.format#fprintf))
@@ -1007,21 +1007,6 @@
 (rewrite 'current-output-port 3 '##sys#standard-output 0)
 (rewrite 'current-error-port 3 '##sys#standard-error 0)
 
-(rewrite
- 'chicken.data-structures#any? 8
- (lambda (db classargs cont callargs) 
-   (and (= 1 (length callargs))
-	(let ((arg (car callargs)))
-	  (make-node
-	   '##core#call (list #t) 
-	   (list cont
-		 (if (and (eq? '##core#variable (node-class arg))
-			  (not (db-get db (car (node-parameters arg)) 'global)) )
-		     (qnode #t)
-		     (make-node 
-		      '##core#inline '("C_anyp")
-		      (list arg)) ) ) ) ) ) ) )
-
 (rewrite
  'chicken.bitwise#bit->boolean 8
  (lambda (db classargs cont callargs)
diff --git a/chicken.h b/chicken.h
index ce4aa9f0..57f99a2c 100644
--- a/chicken.h
+++ b/chicken.h
@@ -1164,7 +1164,6 @@ typedef void (C_ccall *C_proc)(C_word, C_word *) C_noret;
 #define C_anypointerp(x)          C_mk_bool(C_block_header(x) == C_POINTER_TAG || C_block_header(x) == C_TAGGED_POINTER_TAG)
 #define C_specialp(x)             C_mk_bool(C_header_bits(x) & C_SPECIALBLOCK_BIT)
 #define C_byteblockp(x)           C_mk_bool(C_header_bits(x) & C_BYTEBLOCK_BIT)
-#define C_anyp(x)                 C_SCHEME_TRUE
 #define C_sametypep(x, y)         C_mk_bool(C_header_bits(x) == C_header_bits(y))
 #define C_eqp(x, y)               C_mk_bool((x) == (y))
 #define C_vemptyp(x)              C_mk_bool(C_header_size(x) == 0)
diff --git a/data-structures.scm b/data-structures.scm
index fb09dbac..4f8a758d 100644
--- a/data-structures.scm
+++ b/data-structures.scm
@@ -31,7 +31,7 @@
 (module chicken.data-structures
   (alist-ref alist-update alist-update! atom? butlast
    chop compress flatten intersperse join rassoc tail?
-   any? constantly complement compose
+   constantly complement compose
    conjoin disjoin each flip identity list-of? o)
 
 (import scheme chicken)
@@ -115,8 +115,6 @@
 		     (apply h args)
 		     (loop t) ) ) ) ) ) ) ) )
 
-(define (any? x) #t)
-
 
 ;;; List operators:
 
diff --git a/manual/faq b/manual/faq
index f88de23b..4916d793 100644
--- a/manual/faq
+++ b/manual/faq
@@ -516,7 +516,6 @@ and compiler settings:
 The following extended bindings are handled specially: 
 
 {{add1}}
-{{any?}}
 {{arithmetic-shift}}
 {{atom?}}
 {{bignum?}}
diff --git a/types.db b/types.db
index ab17cb9b..081b0e4b 100644
--- a/types.db
+++ b/types.db
@@ -1485,9 +1485,6 @@
           (a b (list-of (pair c d)) #!optional (procedure (a c) *))
           (list-of (pair c (or b d))))))
 
-(chicken.data-structures#any? (#(procedure #:pure #:foldable) chicken.data-structures#any? (*) boolean)
-      ((*) (let ((#(tmp) #(1))) '#t)))
-
 (chicken.data-structures#atom? (#(procedure #:pure #:foldable) chicken.data-structures#atom? (*) boolean)
        ((pair) (let ((#(tmp) #(1))) '#f))
        (((not (or pair list))) (let ((#(tmp) #(1))) '#t)))
Trap