From 29c80d0232b50a54f88e327db7c86492d659de65 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Mon, 28 Jan 2013 21:14:20 -0800 Subject: Make sure we don't have an operator void(), ICC doesn't like it. ICC is right: this function will never be called. But we didn't want it called anyway. Just make it be something non-void. qdbuspendingreply.h(185): error #597: "QDBusPendingReply::operator void() const [with T1=void, T2=void, T3=void, T4=void, T5=void, T6=void, T7=void, T8=void]" will not be called for implicit or explicit conversions Change-Id: I5e067bd03aafc6d6772cc1e0f8f8ae8bfa1712d7 Reviewed-by: Olivier Goffart --- src/dbus/qdbuspendingreply.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/dbus/qdbuspendingreply.h') diff --git a/src/dbus/qdbuspendingreply.h b/src/dbus/qdbuspendingreply.h index d92c817a0a..b7e459f7a7 100644 --- a/src/dbus/qdbuspendingreply.h +++ b/src/dbus/qdbuspendingreply.h @@ -105,6 +105,10 @@ namespace QDBusPendingReplyTypes { static inline void fillMetaTypes(int *) { } }; + + struct TypeIsVoid {}; + template struct NotVoid { typedef T Type; }; + template <> struct NotVoid { typedef TypeIsVoid Type; }; } // namespace QDBusPendingReplyTypes template(); } - inline operator typename Select<0>::Type() const + inline operator typename QDBusPendingReplyTypes::NotVoid::Type() const { return argumentAt<0>(); } -- cgit v1.2.3