qxp::function_ref: try to work around compilation failure on VxWorks
Task-number: QTBUG-115777 Pick-to: 6.6 6.5 Change-Id: Icda59c33ae8c92460c7cb06e204c6b1926b82f66 Reviewed-by: Krzysztof Sommerfeld <krzysztof.sommerfeld@siili.com> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
parent
8723daf696
commit
062718a7d3
@ -108,6 +108,23 @@ public:
|
||||
class F,
|
||||
std::enable_if_t<std::conjunction_v<
|
||||
std::negation<std::is_same<q20::remove_cvref_t<F>, function_ref_base>>,
|
||||
#ifdef Q_OS_VXWORKS
|
||||
// The VxWorks compiler is trying to match this ctor against
|
||||
// qxp::function_ref in lieu of using the copy-constructor, so ban
|
||||
// matching against the equivalent qxp::function_ref here.
|
||||
// This doesn't change anything on other platforms, so to save
|
||||
// on compile-speed, enable it only for VxWorks:
|
||||
std::negation<
|
||||
std::is_same<
|
||||
q20::remove_cvref_t<F>,
|
||||
std::conditional_t<
|
||||
std::is_const_v<Const>,
|
||||
qxp::function_ref<R(ArgTypes...) const noexcept(noex)>,
|
||||
qxp::function_ref<R(ArgTypes...) noexcept(noex)>
|
||||
>
|
||||
>
|
||||
>,
|
||||
#endif // Q_OS_VXWORKS
|
||||
std::negation<std::is_member_pointer<std::remove_reference_t<F>>>,
|
||||
is_invocable_using<copy_const_t<Const, std::remove_reference_t<F>>&>
|
||||
>, bool> = true
|
||||
|
Loading…
Reference in New Issue
Block a user