qlever icon indicating copy to clipboard operation
qlever copied to clipboard

Introduce a Strong Type for Sparql Variables

Open joka921 opened this issue 3 years ago • 0 comments

Previously, all variables were plain std::strings which made them hard to reason about ("does this store a variable, a variable or iri/literal, or does this store an arbitrary string) and easy to make mistakes.

This PR goes one big step in the direction of fixing this, by introducing a SparqlVariable type which cannot be implicitly converted to and from String.

The next step would be to introduce more of those types, e.g.a TripleElement (variable, literal/iri or property path).

joka921 avatar May 11 '21 16:05 joka921