diff --git a/cc/google/fhir/fhir_path/utils.cc b/cc/google/fhir/fhir_path/utils.cc index 7a8790f3a..b6948801e 100644 --- a/cc/google/fhir/fhir_path/utils.cc +++ b/cc/google/fhir/fhir_path/utils.cc @@ -129,7 +129,7 @@ absl::Status RetrieveField( root, &field, [&](const Message& child) { // R4+ packs contained resources in Any protos. if (IsMessageType(child)) { - auto any = google::protobuf::DownCastToGenerated(child); + auto any = google::protobuf::DownCastMessage(child); FHIR_ASSIGN_OR_RETURN( Message * unpacked_message,