mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
AK: Add helper to test for pointer and cv-pointer at the same time
This commit is contained in:
parent
dfe2cf3a40
commit
ceb0e28ea5
Notes:
sideshowbarker
2024-07-17 22:47:04 +09:00
Author: https://github.com/Hendiadyoin1 Commit: https://github.com/SerenityOS/serenity/commit/ceb0e28ea59 Pull-request: https://github.com/SerenityOS/serenity/pull/10808 Reviewed-by: https://github.com/alimpfard Reviewed-by: https://github.com/linusg Reviewed-by: https://github.com/trflynn89 ✅
1 changed files with 2 additions and 0 deletions
|
@ -573,6 +573,8 @@ struct __decay<T[N]> {
|
||||||
template<typename T>
|
template<typename T>
|
||||||
using Decay = typename __decay<T>::type;
|
using Decay = typename __decay<T>::type;
|
||||||
|
|
||||||
|
template<typename T, typename U>
|
||||||
|
inline constexpr bool IsPointerOfType = IsPointer<Decay<U>>&& IsSame<T, RemoveCV<RemovePointer<Decay<U>>>>;
|
||||||
}
|
}
|
||||||
using AK::Detail::AddConst;
|
using AK::Detail::AddConst;
|
||||||
using AK::Detail::AddLvalueReference;
|
using AK::Detail::AddLvalueReference;
|
||||||
|
|
Loading…
Reference in a new issue