X-Git-Url: https://dreyeck.freedombox.rocks/gitweb/topic-maps.git/blobdiff_plain/3924d1eac5a070fe5a6a26683e23ac338793f544..17dd58775e25ab495e3c83deb4b5a36f5e5a124b:/src/tmdm/occurrences.lisp diff --git a/src/tmdm/occurrences.lisp b/src/tmdm/occurrences.lisp index 0dad9c6..5fd761b 100644 --- a/src/tmdm/occurrences.lisp +++ b/src/tmdm/occurrences.lisp @@ -61,6 +61,8 @@ Validate before mutation, return current representative after duplicate replacem ;; TMDM 4.4/5.6: datatype is a locator, never a Topic or a whitelist. (unless (absolute-locator-p datatype) (occurrence-problem :invalid-datatype "Datatype must be a resolved absolute locator.")) + (when (and (string= datatype (integer-datatype)) (not (integer-lexical-p value))) + (occurrence-problem :invalid-integer-value "Value is not an xsd:integer lexical form.")) (when (and (string= datatype (iri-datatype)) (not (absolute-locator-p value))) (occurrence-problem :relative-uri-value "TMDM IRI-valued Occurrences require an absolute locator.")) (let* ((topic (live-topic topic)) (type (live-topic type)) (map (%topic-parent topic)))