Added histogram.lisp to asd file; Moved/added appendf & deletef to sequence.lisp.

Pascal J. Bourguignon [2014-06-23 05:53]
Added histogram.lisp to asd file; Moved/added appendf & deletef to sequence.lisp.
Filename
common-lisp/cesarum/com.informatimago.common-lisp.cesarum.asd
common-lisp/cesarum/list.lisp
common-lisp/cesarum/sequence.lisp
common-lisp/html-parser/parse-html.lisp
rdp/packages.lisp
rdp/rdp.lisp
diff --git a/common-lisp/cesarum/com.informatimago.common-lisp.cesarum.asd b/common-lisp/cesarum/com.informatimago.common-lisp.cesarum.asd
index 95c246e..f0a99a9 100644
--- a/common-lisp/cesarum/com.informatimago.common-lisp.cesarum.asd
+++ b/common-lisp/cesarum/com.informatimago.common-lisp.cesarum.asd
@@ -123,6 +123,7 @@ all written in 100% conforming Common Lisp.
                  (:file "dfa"             :depends-on ())
                  (:file "tea"             :depends-on ())
                  (:file "circular"        :depends-on ())
+                 (:file "histogram"       :depends-on ())

                  ;; Specific stuff:
                  (:file "activity"        :depends-on ())
diff --git a/common-lisp/cesarum/list.lisp b/common-lisp/cesarum/list.lisp
index 653ae98..188401a 100644
--- a/common-lisp/cesarum/list.lisp
+++ b/common-lisp/cesarum/list.lisp
@@ -27,7 +27,7 @@
 ;;;;LEGAL
 ;;;;    AGPL3
 ;;;;
-;;;;    Copyright Pascal J. Bourguignon 2002 - 2013
+;;;;    Copyright Pascal J. Bourguignon 2002 - 2014
 ;;;;
 ;;;;    This program is free software: you can redistribute it and/or modify
 ;;;;    it under the terms of the GNU Affero General Public License as published by
@@ -47,7 +47,7 @@
 (defpackage "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.LIST"
   (:use "COMMON-LISP")
   (:export
-   "PREPENDF"  "PUSH*"
+   "APPENDF" "PREPENDF" "PREPEND" "PUSH*"
    "DLL-NEXT" "DLL-PREVIOUS" "DLL-NODE" "LIST-TO-DOUBLE-LINKED-LIST"
    "EQUIVALENCE-CLASSES" "SUBSETS" "COMBINE" "IOTA"
    "MAKE-LIST-OF-RANDOM-NUMBERS" "LIST-INSERT-SEPARATOR"
@@ -68,7 +68,7 @@ License:

     AGPL3

-    Copyright Pascal J. Bourguignon 2003 - 2013
+    Copyright Pascal J. Bourguignon 2003 - 2014

     This program is free software: you can redistribute it and/or modify
     it under the terms of the GNU Affero General Public License as published by
@@ -88,9 +88,11 @@ License:
 (in-package "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.LIST")


+
 (defun prepend (tail &rest lists)
   (apply (function append) (append lists (list tail))))
-(define-modify-macro prependf (place &rest lists) prepend)
+(define-modify-macro prependf (&rest lists) prepend "Prepend the LISTS at the beginning of the PLACE.")
+(define-modify-macro appendf  (&rest lists)  append "Append the LISTS at the end of the PLACE.")

 (defmacro push* (&rest elements-and-place)
   `(prependf ,(car (last elements-and-place))
diff --git a/common-lisp/cesarum/sequence.lisp b/common-lisp/cesarum/sequence.lisp
index 172ae82..de71cbd 100644
--- a/common-lisp/cesarum/sequence.lisp
+++ b/common-lisp/cesarum/sequence.lisp
@@ -17,7 +17,7 @@
 ;;;;LEGAL
 ;;;;    AGPL3
 ;;;;
-;;;;    Copyright Pascal J. Bourguignon 2012 - 2012
+;;;;    Copyright Pascal J. Bourguignon 2012 - 2014
 ;;;;
 ;;;;    This program is free software: you can redistribute it and/or modify
 ;;;;    it under the terms of the GNU Affero General Public License as published by
@@ -39,7 +39,8 @@
   (:export "HASHED-SET-REMOVE-DUPLICATES"
            "HASHED-REMOVE-DUPLICATES" "HASHED-DELETE-DUPLICATES"
            "DUPLICATES"
-           "REPLACE-SUBSEQ")
+           "REPLACE-SUBSEQ"
+           "DELETEF")
   (:documentation
    "

@@ -50,7 +51,7 @@ License:

     AGPL3

-    Copyright Pascal J. Bourguignon 2004 - 2012
+    Copyright Pascal J. Bourguignon 2004 - 2014

     This program is free software: you can redistribute it and/or modify
     it under the terms of the GNU Affero General Public License as published by
@@ -70,6 +71,14 @@ License:
 (in-package "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.SEQUENCE")


+(defun item-delete (sequence item &rest keys &key from-end test test-not start end count key)
+  (declare (ignore from-end test test-not start end count key))
+  (apply (function delete) item sequence keys))
+
+(define-modify-macro deletef (item &rest keys)
+  item-delete "Delete the item from the sequence in PLACE.")
+
+
 (defun duplicates (sequence &key (test 'eql) (key 'identity))
   "
 RETURN: A sequence of items appearing in SEQUENCE in duplicate.
diff --git a/common-lisp/html-parser/parse-html.lisp b/common-lisp/html-parser/parse-html.lisp
index 127ff94..7e5b18a 100644
--- a/common-lisp/html-parser/parse-html.lisp
+++ b/common-lisp/html-parser/parse-html.lisp
@@ -18,7 +18,7 @@
 ;;;;LEGAL
 ;;;;    AGPL3
 ;;;;
-;;;;    Copyright Pascal J. Bourguignon 2003 - 2012
+;;;;    Copyright Pascal J. Bourguignon 2003 - 2014
 ;;;;
 ;;;;    This program is free software: you can redistribute it and/or modify
 ;;;;    it under the terms of the GNU Affero General Public License as published by
@@ -66,7 +66,7 @@ License:

     AGPL3

-    Copyright Pascal J. Bourguignon 2003 - 2012
+    Copyright Pascal J. Bourguignon 2003 - 2014

     This program is free software: you can redistribute it and/or modify
     it under the terms of the GNU Affero General Public License as published by
@@ -2265,10 +2265,6 @@ to a list of two elements:
 (defstruct cell           attributes lines)


-(define-modify-macro appendf (&rest args)
-  append "Append onto list")
-
-
 (defun collect-table-cells (element)
   (when (listp element)
     (case (html-tag element)
diff --git a/rdp/packages.lisp b/rdp/packages.lisp
index c94a90b..be92204 100644
--- a/rdp/packages.lisp
+++ b/rdp/packages.lisp
@@ -41,6 +41,7 @@
         "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.SEQUENCE"
         "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.CONSTRAINTS"
         "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.PEEK-STREAM"
+        "COM.INFORMATIMAGO.COMMON-LISP.CESARUM.LIST"
         "COM.INFORMATIMAGO.COMMON-LISP.PARSER.SCANNER"
         ;; "COM.INFORMATIMAGO.COMMON-LISP.PARSER.PARSER"
         )
diff --git a/rdp/rdp.lisp b/rdp/rdp.lisp
index 61c5696..fe80521 100644
--- a/rdp/rdp.lisp
+++ b/rdp/rdp.lisp
@@ -349,14 +349,6 @@ PRE:    (non-terminal-p non-terminal)
         `(alt ,rules))))


-(define-modify-macro appendf (&rest args)  append "Append onto list")
-
-(defun prepend (old &rest new-lists)
-  (apply (function append) (append new-lists (list old))))
-(define-modify-macro prependf (&rest args) prepend "Prepend onto list")
-
-
-
 (defun compute-first-sets (grammar)
   "
 PRE:    The GRAMMAR must be normalized.
ViewGit