Commit b76b96e2 authored by david's avatar david

Revision: cxml--devel--1.0--patch-30

Archive: david@knowledgetools.de--cxml
Creator: David Lichteblau <david@knowledgetools.de>
Date: Tue Feb  3 23:49:47 CET 2004
Standard-date: 2004-02-03 22:49:47 GMT
Modified-files: domtest.lisp
New-patches: david@knowledgetools.de--cxml/cxml--devel--1.0--patch-30
Summary: <length/> workaround
Keywords:

+  ;; XXX Soweit ich sehe unterscheiden die Tests nicht zwischen
+  ;; der Laenge von DOMString und der length()-Methode der uebrigen
+  ;; Interfaces.  Also unterscheiden wir das erstmal manuell.
parent 8024ffd0
......@@ -243,6 +243,7 @@
("if" (translate-if element))
("increment" (translate-unary-assignment '+ element))
("decrement" (translate-unary-assignment '- element))
("length" (translate-length element))
("load" (translate-load element))
("plus" (translate-binary-assignment '+ element))
("try" (translate-try element))
......@@ -265,6 +266,17 @@
(maybe-setf (%intern |var|)
`(load-file ,|href| ,(parse-java-literal |willBeModified|)))))
(defun translate-length (load)
;; XXX Soweit ich sehe unterscheiden die Tests nicht zwischen
;; der Laenge von DOMString und der length()-Methode der uebrigen
;; Interfaces. Also unterscheiden wir das erstmal manuell.
(with-attributes (|var| |obj|) load
(let ((obj (%intern |obj|)))
(maybe-setf (%intern |var|)
`(if (typep ,obj 'sequence)
(length ,obj)
(dom:length ,obj))))))
(defun translate-call (call method)
(let ((name (car method))
(args (mapcar (lambda (name)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment