зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1243876 - fix ConvertibleTester to not cause incomplete type errors with UniquePtr and Skia. r=nfroyd
This commit is contained in:
Родитель
6c7038cfd7
Коммит
71421aec25
|
@ -679,18 +679,15 @@ struct IsBaseOf
|
|||
|
||||
namespace detail {
|
||||
|
||||
// This belongs inside ConvertibleTester, but it's pulled out to
|
||||
// work around a bug in the compiler used for hazard builds.
|
||||
template <typename To>
|
||||
static void ConvertibleTestHelper(To);
|
||||
|
||||
template<typename From, typename To>
|
||||
struct ConvertibleTester
|
||||
{
|
||||
private:
|
||||
template<typename From1, typename To1,
|
||||
typename = decltype(ConvertibleTestHelper<To1>(DeclVal<From>()))>
|
||||
static char test(int);
|
||||
template<typename To1>
|
||||
static char test_helper(To1);
|
||||
|
||||
template<typename From1, typename To1>
|
||||
static decltype(test_helper<To1>(DeclVal<From1>())) test(int);
|
||||
|
||||
template<typename From1, typename To1>
|
||||
static int test(...);
|
||||
|
|
Загрузка…
Ссылка в новой задаче