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

Function MakeNestedList

common/expr_test.cc:641–653  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

639}
640
641Expr MakeNestedList(int size) {
642 Expr e;
643 Expr* node = &e;
644 e.set_id(1);
645 for (int i = 0; i < size; ++i) {
646 node = &node->mutable_list_expr()
647 .mutable_elements()
648 .emplace_back()
649 .mutable_expr();
650 node->set_id(i + 2);
651 }
652 return e;
653}
654
655TEST(Expr, FlattenedErase256k) {
656 // Large expr to ensure we're not recursing. Would likely hit stack limits

Callers 1

TESTFunction · 0.85

Calls 1

set_idMethod · 0.45

Tested by

no test coverage detected