| 467 | } |
| 468 | |
| 469 | Json::Value cmFileAPI::BuildReply(Query const& q) |
| 470 | { |
| 471 | Json::Value reply = Json::objectValue; |
| 472 | #ifdef CM_CLANG_SUPPRESS_WARN_RANGE_LOOP_ANALYSIS |
| 473 | # pragma clang diagnostic push |
| 474 | # pragma clang diagnostic ignored "-Wrange-loop-analysis" |
| 475 | #endif |
| 476 | for (Object const o : q.Known) { |
| 477 | #ifdef CM_CLANG_SUPPRESS_WARN_RANGE_LOOP_ANALYSIS |
| 478 | # pragma clang diagnostic pop |
| 479 | #endif |
| 480 | std::string const& name = ObjectName(o); |
| 481 | reply[name] = this->BuildReplyEntry(o); |
| 482 | } |
| 483 | |
| 484 | for (std::string const& name : q.Unknown) { |
| 485 | reply[name] = cmFileAPI::BuildReplyError("unknown query file"); |
| 486 | } |
| 487 | return reply; |
| 488 | } |
| 489 | |
| 490 | Json::Value cmFileAPI::BuildReplyEntry(Object object) |
| 491 | { |
no test coverage detected