Register named blank nodes
turtle/tordf.scm
| 84 | 84 | (() ""))) | |
| 85 | 85 | ||
| 86 | 86 | (define (parse-iri iri state) | |
| 87 | - | (pk 'iri iri) | |
| 88 | 87 | (match iri | |
| 89 | 88 | (('iri ('prefixed-name ('pname-ln ('pname-ns ns) ('pn-local suffix)))) | |
| 90 | 89 | `(("iri" . ,(string-append (assoc-ref (parser-state-namespaces state) ns) | |
… | |||
| 222 | 221 | (('blank-node ('blank-node-label label)) | |
| 223 | 222 | (let* ((node | |
| 224 | 223 | (or (assoc-ref (parser-state-bnode-labels state) label) | |
| 225 | - | ((parser-state-blank-node-gen state))))) | |
| 224 | + | ((parser-state-blank-node-gen state)))) | |
| 225 | + | (state | |
| 226 | + | (if (assoc-ref (parser-state-bnode-labels state) label) | |
| 227 | + | state | |
| 228 | + | (update-parser-state state | |
| 229 | + | #:bnode-labels | |
| 230 | + | (cons | |
| 231 | + | (cons label node) | |
| 232 | + | (parser-state-bnode-labels state)))))) | |
| 226 | 233 | (update-parser-state state | |
| 227 | 234 | #:cur-object node | |
| 228 | 235 | #:result | |