csslike* is a terrible name, use css-selector* instead
Fri Nov 13 04:24:11 UTC 2009 pix@kepibu.org
* csslike* is a terrible name, use css-selector* instead
diff -rN -u old-Oh, Ducks!/package.lisp new-Oh, Ducks!/package.lisp
--- old-Oh, Ducks!/package.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/package.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,3 +1,3 @@
-(defpackage #:csslike-unifier
+(defpackage #:css-selector-unifier
(:use #:cl #:unify)
(:export #:lhtml))
diff -rN -u old-Oh, Ducks!/regexp-template.lisp new-Oh, Ducks!/regexp-template.lisp
--- old-Oh, Ducks!/regexp-template.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/regexp-template.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,7 +1,7 @@
;;;; we add an automagical &rest, because cl-unification's cl-ppcre support
;;;; requires matching the entire string, and we're generally concerned with
;;;; just the beginning of it.
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
(defmethod make-template ((kind (eql 'regexp+)) (spec cons))
(destructuring-bind (re-kwd regexp &optional vars &rest keys)
diff -rN -u old-Oh, Ducks!/tests.lisp new-Oh, Ducks!/tests.lisp
--- old-Oh, Ducks!/tests.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/tests.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,4 +1,4 @@
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
(equalp '(:div ((:id "id")) "I " (:i () "like") " cheese.")
(match (#T(lhtml ("#id" . ?div))
diff -rN -u old-Oh, Ducks!/traversal/interface.lisp new-Oh, Ducks!/traversal/interface.lisp
--- old-Oh, Ducks!/traversal/interface.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/traversal/interface.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,7 +1,7 @@
;;;; type-defines-accessors
;;;; Under this implementation strategy, elements would need only implement
;;;; accessors for traversing the node graph.
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
;;; general accessors
diff -rN -u old-Oh, Ducks!/traversal/lhtml.lisp new-Oh, Ducks!/traversal/lhtml.lisp
--- old-Oh, Ducks!/traversal/lhtml.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/traversal/lhtml.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,7 +1,7 @@
;;; WARNING: lhtml will conflict with any handler which also uses lists.
;;; xmls, for instance (though I think that's at least
;;; structurally compatible). Sorry, but that's the way it goes.
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
;;; general accessors
diff -rN -u old-Oh, Ducks!/traversal/pt.lisp new-Oh, Ducks!/traversal/pt.lisp
--- old-Oh, Ducks!/traversal/pt.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/traversal/pt.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,4 +1,4 @@
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
;;; general accessors
diff -rN -u old-Oh, Ducks!/unification-templates.lisp new-Oh, Ducks!/unification-templates.lisp
--- old-Oh, Ducks!/unification-templates.lisp 2015-04-10 16:11:19.000000000 +0000
+++ new-Oh, Ducks!/unification-templates.lisp 2015-04-10 16:11:19.000000000 +0000
@@ -1,17 +1,15 @@
-;; FIXME: rename from csslike to css-selector...so css-selector-unifier and
-;; css-selector-template. Much nicer name, methinks.
-(in-package #:csslike-unifier)
+(in-package #:css-selector-unifier)
-(defclass csslike-template (unify::expression-template)
+(defclass css-selector-template (unify::expression-template)
(#+(or)
(parser :reader parser) ;; subtype determines parser
(handler :reader handler) ;; cxml/closure-html handler
(specifiers :reader specifiers) ;; list of (specifier . variable) and (specifier . template)
))
-(defclass xml-template (csslike-template) ()) ;; parses using closure-xml
+(defclass xml-template (css-selector-template) ()) ;; parses using closure-xml
-(defclass html-template (csslike-template) ()) ;; parses using closure-html
+(defclass html-template (css-selector-template) ()) ;; parses using closure-html
(defclass lhtml-template (html-template) ())
(defclass pt-template (html-template) ())
@@ -36,14 +34,14 @@
((unify::variablep rest) rest)
((consp rest) (make-instance template-kind :css-specifiers rest))))))
-(defmethod unify ((a csslike-template) (b csslike-template)
+(defmethod unify ((a css-selector-template) (b css-selector-template)
&optional (env (make-empty-environment))
&key &allow-other-keys)
(error 'unification-failure
- :format-control "Do not know how to unify the two csslike-templates ~S and ~S."
+ :format-control "Do not know how to unify the two css-selector-templates ~S and ~S."
:format-arguments (list a b)))
-(defmethod unify ((template csslike-template) document
+(defmethod unify ((template css-selector-template) document
&optional (env (make-empty-environment))
&key &allow-other-keys)
(format t "ts: ~s~%" (template-spec template))