[libcxx-commits] [PATCH] D129716: [libc++][NFC] Use is_void instead of is_same<void, ...>
Mark de Wever via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sun Jul 17 07:04:29 PDT 2022
Mordante added a comment.
In D129716#3656967 <https://reviews.llvm.org/D129716#3656967>, @nilayvaish wrote:
> In D129716#3655911 <https://reviews.llvm.org/D129716#3655911>, @Mordante wrote:
>
>> Can you explain what the benefit of this change is? And why the different behaviour of `std::same_as` and `std::is_void_v` is not an issue. I'm not even sure we should call this an NFC patch.
>>
>> In general it would be good to add this kind of information to the commit message/review description.
>
> The patch is replacing `std::is_same` with a more specialized version `std::is_void`. This patch seems fine to me. Two questions:
`std::is_void` is less specialized. After the change cv-qualified void types are accepted. https://godbolt.org/z/j66MsThYs
> - Why do we have the specialized version at all?
You mean `std::is_void`? (If yes, that's required by the Standard.)
> - Why does `std::same_as` matter here?
Sorry I don't understand the question, can you rephrase it?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129716/new/
https://reviews.llvm.org/D129716
More information about the libcxx-commits
mailing list