Variables are not allowed in NegatedPropertySet

pull/10/head
Tpt 6 years ago
parent f3ab335ad3
commit 028910b77c
  1. 2
      src/sparql/algebra.rs
  2. 10
      src/sparql/sparql_grammar.rustpeg

@ -14,7 +14,7 @@ pub enum PropertyPath {
ZeroOrMorePath(Box<PropertyPath>),
OneOrMorePath(Box<PropertyPath>),
ZeroOrOnePath(Box<PropertyPath>),
NegatedPropertySet(Vec<NamedNodeOrVariable>),
NegatedPropertySet(Vec<NamedNode>),
}
impl fmt::Display for PropertyPath {

@ -563,12 +563,14 @@ PathNegatedPropertySet -> PropertyPath =
Either::Right(b) => PropertyPath::InversePath(Box::new(PropertyPath::NegatedPropertySet(vec![b]))),
}
}
PathNegatedPropertySet_item -> Either<NamedNodeOrVariable,NamedNodeOrVariable> = p:PathOneInPropertySet _ { p }
PathNegatedPropertySet_item -> Either<NamedNode,NamedNode> = p:PathOneInPropertySet _ { p }
//[96]
PathOneInPropertySet -> Either<NamedNodeOrVariable,NamedNodeOrVariable> =
'^' _ v:Verb { Either::Right(v) } /
v:Verb { Either::Left(v) }
PathOneInPropertySet -> Either<NamedNode,NamedNode> =
'^' _ 'a' { Either::Right(rdf::TYPE.clone()) } /
'^' _ v:iri { Either::Right(v) } /
'a' { Either::Left(rdf::TYPE.clone()) } /
v:iri { Either::Left(v) }
//[98]
TriplesNode -> FocusedTriplePattern<TermOrVariable> = Collection / BlankNodePropertyList

Loading…
Cancel
Save