<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/80217>80217</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            PSTL inplace_merge test uses invalid comparison function
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          jwakely
      </td>
    </tr>
</table>

<pre>
    https://github.com/llvm/llvm-project/blob/24a804101b67676aa9fa7f1097043ddd9e2ac1b6/pstl/test/std/algorithms/alg.merge/inplace_merge.pass.cpp#L153

This gets passed to `std::inplace_merge` but that requires an ordering comparison, not an equality predicate.

I think the fix is simply:

```diff
--- a/pstl/test/std/algorithms/alg.merge/inplace_merge.pass.cpp
+++ b/pstl/test/std/algorithms/alg.merge/inplace_merge.pass.cpp
@@ -150,7 +150,7 @@ main()
     test_by_type<MemoryChecker>(
 [](std::size_t idx){ return MemoryChecker{std::int32_t(idx * 2)}; },
 [](std::size_t idx){ return MemoryChecker{std::int32_t(idx * 2 + 1)}; },
-        [](const MemoryChecker& val1, const MemoryChecker& val2){ return val1.value() == val2.value(); });
+        [](const MemoryChecker& val1, const MemoryChecker& val2){ return val1.value() < val2.value(); });
 EXPECT_FALSE(MemoryChecker::alive_objects() < 0, "wrong effect from inplace_merge: number of ctors calls < num of dtors calls");
 EXPECT_FALSE(MemoryChecker::alive_objects() > 0, "wrong effect from inplace_merge: number of ctors calls > num of dtors calls");
 
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy8VV-PozYQ_zTmZZTIjAkkDzzkzyJV2kon3T70LTIwgG8N5myT3fTTV4Y2l6xa6Sptiyxsz5_f_DQezUjnVDsQ5WxzYJtTJCffGZt_e5OvpK9Raepr3nk_Oib2DAuGRat8N5XryvQMC60vf22r0ZpvVHmGRalNybDARG55EvO4TLM0S6XcNTJrYr7LeCLqut4RyiouU4bF6LxmWHhywd_5mmEhdWus8l3vlsu6J9sSw0INo5YVnef7epTOratxZCie441g_MT4fvm_dMpBS95BMKIavAGW8gAv9kzsH4BYyqGcPPhOerD0fVKWHMgBjK3JqqGFyvSjtMqZgeERBuODlr5PUit_hdFSrSrpaX1P4RfwnRpewXcEjXoH5cCpftTXwODOjqV8WbVqmkW0Wq1AflJulhh4WBaUnwqbcJZwWMUbzvCYAcPD7bioeqkGhluGu8UDwhcCn8vr2V9HYuL4K_XGXo8dVa9kmXgK9ovxUpkMt7d3c-p3OntQ9XuAzA5gyU92gEeM7HD30F7g2TPcqvodGO4BZ88TEwcIGx7_02AhJxD_fcgV_PndQldmcP4DPqZwkToOhffPanxkGBzWF6knWpIPTJyYOM2W9_Ibo3C6lcr_Sev4M5zg6bcvT8eXc7F__hrK40PFhNRLrS50NmXoQ-4OPVQjMMQ3a4YWqGmo8tBY08NjCxB7GKa-JAumgcob66CSWrsZZJj6IK5_iBnipxB8-gyCTz9B8EOviepc1DuxkxHlccbTLBG7JI66XFZluokFF5iUCTWiKneckibb1vFuuy23kcqRY8JjEaMQiPGaqrKhpomJ84walCzh1Eul12E0rI1tI-XcRPmWY5xFWpak3TxzEAd6g1kZ2G5Okc3ncVJOrWMJ18p59wPFK68p__L15fkxM3M7gcmRAzVcpFb1XbuGZhoqr8wQTVb_-3E2kwsdcSb_RwAAAP__yNg0Vw">