tst_qvariant: automate testing of forward_list
...using the SD-6 __has_include macro. Change-Id: I629e2ad1c8090aba9e86ab9febf6d09a504219f9 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This commit is contained in:
parent
38c2e3d104
commit
11e09a440b
@ -3798,11 +3798,10 @@ struct ContainerAPI<Container, QByteArray>
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// We have no built-in defines to check the stdlib features.
|
#ifdef __has_include
|
||||||
// #define TEST_FORWARD_LIST
|
# if __has_include(<forward_list>)
|
||||||
|
# define TEST_FORWARD_LIST
|
||||||
#ifdef TEST_FORWARD_LIST
|
# include <forward_list>
|
||||||
#include <forward_list>
|
|
||||||
|
|
||||||
Q_DECLARE_SEQUENTIAL_CONTAINER_METATYPE(std::forward_list)
|
Q_DECLARE_SEQUENTIAL_CONTAINER_METATYPE(std::forward_list)
|
||||||
|
|
||||||
@ -3856,7 +3855,8 @@ struct ContainerAPI<std::forward_list<QString> >
|
|||||||
return variant == value;
|
return variant == value;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
#endif
|
# endif // __has_include(<forward_list>)
|
||||||
|
#endif // __has_include
|
||||||
|
|
||||||
template<typename Container>
|
template<typename Container>
|
||||||
struct KeyGetter
|
struct KeyGetter
|
||||||
|
Loading…
Reference in New Issue
Block a user