| 137 | } |
| 138 | |
| 139 | absl::Status ParsedMessageValue::Equal( |
| 140 | const Value& other, |
| 141 | const google::protobuf::DescriptorPool* absl_nonnull descriptor_pool, |
| 142 | google::protobuf::MessageFactory* absl_nonnull message_factory, |
| 143 | google::protobuf::Arena* absl_nonnull arena, Value* absl_nonnull result) const { |
| 144 | ABSL_DCHECK(descriptor_pool != nullptr); |
| 145 | ABSL_DCHECK(message_factory != nullptr); |
| 146 | ABSL_DCHECK(arena != nullptr); |
| 147 | ABSL_DCHECK(result != nullptr); |
| 148 | |
| 149 | if (auto other_message = other.AsParsedMessage(); other_message) { |
| 150 | CEL_ASSIGN_OR_RETURN( |
| 151 | auto equal, internal::MessageEquals(*value_, **other_message, |
| 152 | descriptor_pool, message_factory)); |
| 153 | *result = BoolValue(equal); |
| 154 | return absl::OkStatus(); |
| 155 | } |
| 156 | if (auto other_struct = other.AsStruct(); other_struct) { |
| 157 | return common_internal::StructValueEqual(StructValue(*this), *other_struct, |
| 158 | descriptor_pool, message_factory, |
| 159 | arena, result); |
| 160 | } |
| 161 | *result = BoolValue(false); |
| 162 | return absl::OkStatus(); |
| 163 | } |
| 164 | |
| 165 | ParsedMessageValue ParsedMessageValue::Clone( |
| 166 | google::protobuf::Arena* absl_nonnull arena) const { |
nothing calls this directly
no test coverage detected