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

Function OptionalValueDebugString

common/values/optional_value.cc:68–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

66}
67
68std::string OptionalValueDebugString(
69 const OpaqueValueDispatcher* absl_nonnull dispatcher,
70 OpaqueValueContent content) {
71 if (!static_cast<const OptionalValueDispatcher*>(dispatcher)
72 ->has_value(static_cast<const OptionalValueDispatcher*>(dispatcher),
73 content)) {
74 return "optional.none()";
75 }
76 Value value;
77 static_cast<const OptionalValueDispatcher*>(dispatcher)
78 ->value(static_cast<const OptionalValueDispatcher*>(dispatcher), content,
79 &value);
80 return absl::StrCat("optional.of(", value.DebugString(), ")");
81}
82
83bool OptionalValueHasValue(const OptionalValueDispatcher* absl_nonnull,
84 OpaqueValueContent) {

Callers

nothing calls this directly

Calls 3

has_valueMethod · 0.45
valueMethod · 0.45
DebugStringMethod · 0.45

Tested by

no test coverage detected