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

Function PushStructDeps

common/ast_traverse.cc:220–231  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

218}
219
220void PushStructDeps(const StructExpr* struct_expr,
221 std::stack<StackRecord>* stack) {
222 const auto& entries = struct_expr->fields();
223 for (auto it = entries.rbegin(); it != entries.rend(); ++it) {
224 const auto& entry = *it;
225 // The contract is to visit key, then value. So put them on the stack
226 // in the opposite order.
227 if (entry.has_value()) {
228 stack->push(StackRecord(&entry.value()));
229 }
230 }
231}
232
233void PushMapDeps(const MapExpr* map_expr, std::stack<StackRecord>* stack) {
234 const auto& entries = map_expr->entries();

Callers 1

operator()Method · 0.70

Calls 3

StackRecordClass · 0.70
has_valueMethod · 0.45
valueMethod · 0.45

Tested by

no test coverage detected