MCPcopy Create free account
hub / github.com/Aloshi/EmulationStation / parse_union_expression

Method parse_union_expression

src/pugiXML/pugixml.cpp:9388–9405  ·  view source on GitHub ↗

UnionExpr ::= PathExpr | UnionExpr '|' PathExpr

Source from the content-addressed store, hash-verified

9386
9387 // UnionExpr ::= PathExpr | UnionExpr '|' PathExpr
9388 xpath_ast_node* parse_union_expression()
9389 {
9390 xpath_ast_node* n = parse_path_expression();
9391
9392 while (_lexer.current() == lex_union)
9393 {
9394 _lexer.next();
9395
9396 xpath_ast_node* expr = parse_union_expression();
9397
9398 if (n->rettype() != xpath_type_node_set || expr->rettype() != xpath_type_node_set)
9399 throw_error("Union operator has to be applied to node sets");
9400
9401 n = new (alloc_node()) xpath_ast_node(ast_op_union, xpath_type_node_set, n, expr);
9402 }
9403
9404 return n;
9405 }
9406
9407 // UnaryExpr ::= UnionExpr | '-' UnaryExpr
9408 xpath_ast_node* parse_unary_expression()

Callers

nothing calls this directly

Calls 3

currentMethod · 0.80
nextMethod · 0.80
rettypeMethod · 0.80

Tested by

no test coverage detected