SWI-Prolog / packages-semweb

The SWI-Prolog RDF store
28 stars 14 forks source link

TriG export incorrectly includes default graph name #75

Open wouterbeek opened 6 years ago

wouterbeek commented 6 years ago

Steps to reproduce:

?- [library(semweb/rdf_db)].
?- [library(semweb/turtle)].
?- rdf_assert(rdf:s, rdf:p, rdf:o).
?- rdf_save_canonical_trig('test.trig', []).

File test.trig now has the following content:

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
<user> {
rdf:s rdf:p rdf:o .
}

Notice that <user> is not a legal IRI.

Expected: TriG to not export the <...> { ... } graph notation for triples in the default graph.