diff options
Diffstat (limited to 'module/sxml/namespaced/util.scm')
-rw-r--r-- | module/sxml/namespaced/util.scm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/module/sxml/namespaced/util.scm b/module/sxml/namespaced/util.scm index 9a4e72d7..e60254b7 100644 --- a/module/sxml/namespaced/util.scm +++ b/module/sxml/namespaced/util.scm @@ -2,6 +2,7 @@ :use-module (sxml namespaced) :use-module (srfi srfi-1) :use-module ((ice-9 control) :select (call/ec)) + :use-module (hnh util type) :export (xml-element-hash-key find-child element-matches? @@ -14,6 +15,8 @@ (xml-element-tagname tag))) (define (find-child target list) + (typecheck target xml-element?) + (typecheck list (list-of (or xml-element? string?))) (define target* (xml-element-hash-key target)) (find (lambda (x) (and (xml-element? x) (equal? target* (xml-element-hash-key x)))) |