Closed jeswr closed 2 months ago
This test https://github.com/rdfjs/N3.js/blob/a8cd43609e0d83edcd1f2b64d164760e68eaebb0/test/Term-test.js#L211-L213 fails as termFromId does not handle nested quads. This is because this regex (https://github.com/rdfjs/N3.js/blob/e531951ac7f3ec085fb7faab8f1d746a0f8c2fef/src/N3DataFactory.js#L13) cannot handle one of the terms being a quad.
termFromId
Trying to look into a fix but am struggling to get the regex for it right.
am struggling to get the regex for it right
If the nesting is arbitrarily deep, no regex can capture it, so we'd need to actually parse.
Resolved in https://github.com/rdfjs/N3.js/commit/e1cc8dd41f6fe407ac224121cd85c94307e33dae
This test https://github.com/rdfjs/N3.js/blob/a8cd43609e0d83edcd1f2b64d164760e68eaebb0/test/Term-test.js#L211-L213 fails as
termFromId
does not handle nested quads. This is because this regex (https://github.com/rdfjs/N3.js/blob/e531951ac7f3ec085fb7faab8f1d746a0f8c2fef/src/N3DataFactory.js#L13) cannot handle one of the terms being a quad.Trying to look into a fix but am struggling to get the regex for it right.