element-parent now works in lhtml
Mon Jan 4 07:11:36 UTC 2010 pix@kepibu.org
* element-parent now works in lhtml
diff -rN -u old-Oh, Ducks!/tests.lisp new-Oh, Ducks!/tests.lisp
--- old-Oh, Ducks!/tests.lisp 2013-07-24 10:35:10.000000000 +0000
+++ new-Oh, Ducks!/tests.lisp 2013-07-24 10:35:10.000000000 +0000
@@ -23,22 +23,23 @@
(values divs pig)))
(equalp '((:i () "not") (:i () "cheese"))
- (match (#T(html ("div" ("i" . ?i)))
- "<div>I do <i>not</i> like cheese.</div><div>I like <i>cheese</i>.</div>")
+ (match (#T(html (:model lhtml)
+ ("div" ("i" . ?i)))
+ "<div>I do <i>not</i> like cheese.</div><div>I like <i>cheese</i>.</div>")
i))
(equalp '((:i () "not"))
- (match (#T(html (:model dom)
+ (match (#T(html (:model lhtml)
("div>i" . ?i))
- "<div>I do <i>not</i> like cheese.</div><div><span>I like <i>cheese</i>.</span></div>")
+ "<div>I do <i>not</i> like cheese.</div><div><span>I like <i>cheese</i>.</span></div>")
i))
(equalp '((:i () "not"))
- (match (#T(html (:model dom)
+ (match (#T(html (:model lhtml)
("div" (">i" . ?i)
;("i" . #t(list ?j ?i))
("span>i" . ?span)))
- "<div>I do <i>not</i> like cheese.</div><div><span>I like <i>cheese</i>.</span></div>")
+ "<div>I do <i>not</i> like cheese.</div><div><span>I like <i>cheese</i>.</span></div>")
(values i span)))
(match (#T(html (:model dom)
diff -rN -u old-Oh, Ducks!/unify.lisp new-Oh, Ducks!/unify.lisp
--- old-Oh, Ducks!/unify.lisp 2013-07-24 10:35:10.000000000 +0000
+++ new-Oh, Ducks!/unify.lisp 2013-07-24 10:35:10.000000000 +0000
@@ -37,7 +37,7 @@
;;; descendant combinator to be sure, but the general one (#\Space) doesn't
;;; exactly show up all that well. Somebody might assume " b" was the same as
;;; "b" and get confused.
- ((ignore-errors (element-parent document)) ; bleh. element-parent breaks lhtml nodes
+ ((element-parent document)
(subjects-in-list css-specifier (element-children document)))
;; root element includes itself
(t (subjects-of css-specifier document)))))