| 311 | |
| 312 | |
| 313 | bool ExprNode::dsqlMatch(DsqlCompilerScratch* dsqlScratch, const ExprNode* other, bool ignoreMapCast) const |
| 314 | { |
| 315 | if (other->getType() != getType()) |
| 316 | return false; |
| 317 | |
| 318 | NodeRefsHolder thisHolder(dsqlScratch->getPool()); |
| 319 | getChildren(thisHolder, true); |
| 320 | |
| 321 | NodeRefsHolder otherHolder(dsqlScratch->getPool()); |
| 322 | other->getChildren(otherHolder, true); |
| 323 | |
| 324 | size_t count = thisHolder.refs.getCount(); |
| 325 | if (otherHolder.refs.getCount() != count) |
| 326 | return false; |
| 327 | |
| 328 | const auto* j = otherHolder.refs.begin(); |
| 329 | |
| 330 | for (const auto i : thisHolder.refs) |
| 331 | { |
| 332 | if (!*i != !**j || !PASS1_node_match(dsqlScratch, *i, **j, ignoreMapCast)) |
| 333 | return false; |
| 334 | |
| 335 | ++j; |
| 336 | } |
| 337 | |
| 338 | return true; |
| 339 | } |
| 340 | |
| 341 | bool ExprNode::sameAs(const ExprNode* other, bool ignoreStreams) const |
| 342 | { |
nothing calls this directly
no test coverage detected