[PATCH] D141892: Implement modernize-use-constraints

Chris Cotter via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 16 22:40:01 PST 2023


ccotter added a comment.

Overall, we could eventually upgrade code in three stages, each a separate reusable check.

1. enable_if -> requires clauses
2. replace the non `_v` templates to the `_v` variants `is_same` -> `is_same_v` or the equivalent concept `same_as`
3. replace requires clause on declarations to be template type constraint (replace `template <typename T> void foo() requires std::same_as<T, int> void foo() {}` to `template <std::same_as<int> T> void foo() {}`


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D141892/new/

https://reviews.llvm.org/D141892



More information about the cfe-commits mailing list