mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-10 05:41:40 +00:00
Use the same tag type across all PointerLikeTypeTraits specializations
Works around a bug (PR28216) in Clang's MS mangling of templates with partial specializations. This mismatch was introduced in about six months ago in r256656. llvm-svn: 273223
This commit is contained in:
parent
96c0eb45f8
commit
4b1a130643
@ -37,7 +37,8 @@ template <> struct ConstantLog2<1> : std::integral_constant<size_t, 0> {};
|
||||
}
|
||||
|
||||
// Provide PointerLikeTypeTraits for non-cvr pointers.
|
||||
template <typename T> struct PointerLikeTypeTraits<T *> {
|
||||
template <typename T> class PointerLikeTypeTraits<T *> {
|
||||
public:
|
||||
static inline void *getAsVoidPointer(T *P) { return P; }
|
||||
static inline T *getFromVoidPointer(void *P) { return static_cast<T *>(P); }
|
||||
|
||||
@ -46,7 +47,8 @@ template <typename T> struct PointerLikeTypeTraits<T *> {
|
||||
};
|
||||
};
|
||||
|
||||
template <> struct PointerLikeTypeTraits<void *> {
|
||||
template <> class PointerLikeTypeTraits<void *> {
|
||||
public:
|
||||
static inline void *getAsVoidPointer(void *P) { return P; }
|
||||
static inline void *getFromVoidPointer(void *P) { return P; }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user