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

Function xmlXPathCompEqualityExpr

ThirdParty/libxml2/vtklibxml2/xpath.c:9854–9873  ·  view source on GitHub ↗

* xmlXPathCompEqualityExpr: * @ctxt: the XPath Parser context * * [23] EqualityExpr ::= RelationalExpr * | EqualityExpr '=' RelationalExpr * | EqualityExpr '!=' RelationalExpr * * A != B != C is allowed ? Answer from James, yes with * (RelationalExpr = RelationalExpr) = RelationalExpr * (RelationalExpr != RelationalExpr) != RelationalExpr * which

Source from the content-addressed store, hash-verified

9852 *
9853 */
9854static void
9855xmlXPathCompEqualityExpr(xmlXPathParserContextPtr ctxt) {
9856 xmlXPathCompRelationalExpr(ctxt);
9857 CHECK_ERROR;
9858 SKIP_BLANKS;
9859 while ((CUR == '=') || ((CUR == '!') && (NXT(1) == '='))) {
9860 int eq;
9861 int op1 = ctxt->comp->last;
9862
9863 if (CUR == '=') eq = 1;
9864 else eq = 0;
9865 NEXT;
9866 if (!eq) NEXT;
9867 SKIP_BLANKS;
9868 xmlXPathCompRelationalExpr(ctxt);
9869 CHECK_ERROR;
9870 PUSH_BINARY_EXPR(XPATH_OP_EQUAL, op1, ctxt->comp->last, eq, 0);
9871 SKIP_BLANKS;
9872 }
9873}
9874
9875/**
9876 * xmlXPathCompAndExpr:

Callers 1

xmlXPathCompAndExprFunction · 0.85

Calls 1

Tested by

no test coverage detected