MCPcopy Create free account
hub / github.com/Kitware/VTK / xmlXPathCompPrimaryExpr

Function xmlXPathCompPrimaryExpr

ThirdParty/libxml2/vtklibxml2/xpath.c:9423–9445  ·  view source on GitHub ↗

* xmlXPathCompPrimaryExpr: * @ctxt: the XPath Parser context * * [15] PrimaryExpr ::= VariableReference * | '(' Expr ')' * | Literal * | Number * | FunctionCall * * Compile a primary expression. */

Source from the content-addressed store, hash-verified

9421 * Compile a primary expression.
9422 */
9423static void
9424xmlXPathCompPrimaryExpr(xmlXPathParserContextPtr ctxt) {
9425 SKIP_BLANKS;
9426 if (CUR == '$') xmlXPathCompVariableReference(ctxt);
9427 else if (CUR == '(') {
9428 NEXT;
9429 SKIP_BLANKS;
9430 xmlXPathCompileExpr(ctxt, 1);
9431 CHECK_ERROR;
9432 if (CUR != ')') {
9433 XP_ERROR(XPATH_EXPR_ERROR);
9434 }
9435 NEXT;
9436 SKIP_BLANKS;
9437 } else if (IS_ASCII_DIGIT(CUR) || (CUR == '.' && IS_ASCII_DIGIT(NXT(1)))) {
9438 xmlXPathCompNumber(ctxt);
9439 } else if ((CUR == '\'') || (CUR == '"')) {
9440 xmlXPathCompLiteral(ctxt);
9441 } else {
9442 xmlXPathCompFunctionCall(ctxt);
9443 }
9444 SKIP_BLANKS;
9445}
9446
9447/**
9448 * xmlXPathCompFilterExpr:

Callers 1

xmlXPathCompFilterExprFunction · 0.85

Calls 5

xmlXPathCompileExprFunction · 0.85
xmlXPathCompNumberFunction · 0.85
xmlXPathCompLiteralFunction · 0.85
xmlXPathCompFunctionCallFunction · 0.85

Tested by

no test coverage detected