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

Method Append

common/values/value_builder.cc:458–470  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

456 int size() const override { return static_cast<int>(Size()); }
457
458 absl::Status Append(Value value) const override {
459 CEL_RETURN_IF_ERROR(CheckListElement(value));
460 elements_.emplace_back(std::move(value));
461 if (elements_trivially_destructible_) {
462 elements_trivially_destructible_ =
463 ArenaTraits<>::trivially_destructible(elements_.back());
464 if (!elements_trivially_destructible_) {
465 elements_.get_allocator().arena()->OwnDestructor(
466 const_cast<MutableCompatListValueImpl*>(this));
467 }
468 }
469 return absl::OkStatus();
470 }
471
472 void Reserve(size_t capacity) const override { elements_.reserve(capacity); }
473

Callers 9

AbslStringifyFunction · 0.45
AbslStringifyFunction · 0.45
AbslStringifyFunction · 0.45
ConcatMethod · 0.45
AppendToCordMethod · 0.45
TEST_PFunction · 0.45
LowerAsciiImplFunction · 0.45
UpperAsciiImplFunction · 0.45
TEST_FFunction · 0.45

Calls 2

CheckListElementFunction · 0.85
arenaMethod · 0.45

Tested by 2

TEST_PFunction · 0.36
TEST_FFunction · 0.36