/////////////////////////////////////////////////////////////////////////// Equality --> Comparative {( "==" | "=" | "!==" | "!=" ) Comparative}
| 441 | //////////////////////////////////////////////////////////////////////////////// |
| 442 | // Equality --> Comparative {( "==" | "=" | "!==" | "!=" ) Comparative} |
| 443 | bool Eval::parseEquality(std::vector<std::pair<std::string, Lexer::Type>>& infix, |
| 444 | unsigned int& i) const { |
| 445 | if (i < infix.size() && parseComparative(infix, i)) { |
| 446 | while (i < infix.size() && infix[i].second == Lexer::Type::op && |
| 447 | (infix[i].first == "==" || infix[i].first == "=" || infix[i].first == "!==" || |
| 448 | infix[i].first == "!=")) { |
| 449 | ++i; |
| 450 | if (!parseComparative(infix, i)) return false; |
| 451 | } |
| 452 | |
| 453 | return true; |
| 454 | } |
| 455 | |
| 456 | return false; |
| 457 | } |
| 458 | |
| 459 | //////////////////////////////////////////////////////////////////////////////// |
| 460 | // Comparative --> Arithmetic {( "<=" | "<" | ">=" | ">" ) Arithmetic} |
nothing calls this directly
no outgoing calls
no test coverage detected