MCPcopy Create free account
hub / github.com/cel-expr/cel-cpp / VisitExistsMacro

Method VisitExistsMacro

tools/cel_unparser.cc:374–384  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

372}
373
374absl::Status Unparser::VisitExistsMacro(const Expr::Comprehension& expr) {
375 if (expr.loop_step().call_expr().args_size() != 2) {
376 return absl::InvalidArgumentError(
377 absl::StrCat("Unexpected exists macro: ", expr.ShortDebugString()));
378 }
379
380 Print(CelOperator::EXISTS, kLeftParen, expr.iter_var(), kComma, kSpace);
381 CEL_RETURN_IF_ERROR(Visit(expr.loop_step().call_expr().args(1)));
382 Print(kRightParen);
383 return absl::OkStatus();
384}
385
386absl::Status Unparser::VisitExistsOneMacro(const Expr::Comprehension& expr) {
387 if (expr.loop_step().call_expr().args_size() != 3) {

Callers

nothing calls this directly

Calls 2

argsMethod · 0.80
VisitFunction · 0.50

Tested by

no test coverage detected