From 0c4f6c6ea9415bcc5fde3e34bf909f43a9c6483c Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Tue, 8 Jan 2013 10:31:26 -0200 Subject: Fix compilation of Qt Concurrent with gcc 4.3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit GCC 4.3 had support for decltype but not the new function syntax (which we call "auto function" for short). That meant the code did not compile. qtconcurrentrun.h:105: error: expected initializer before ‘->’ token Task-number: QTBUG-28984 Change-Id: I792276ec59c4f6e73f6137c517636e70c71ed849 Reviewed-by: Olivier Goffart --- src/concurrent/qtconcurrentrun.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/concurrent') diff --git a/src/concurrent/qtconcurrentrun.h b/src/concurrent/qtconcurrentrun.h index 0c173d267c..3ac09fc98f 100644 --- a/src/concurrent/qtconcurrentrun.h +++ b/src/concurrent/qtconcurrentrun.h @@ -98,7 +98,7 @@ QFuture run(T (*functionPointer)(Param1, Param2, Param3, Param4, Param5), con return (new StoredFunctorCall5(functionPointer, arg1, arg2, arg3, arg4, arg5))->start(); } -#ifdef Q_COMPILER_DECLTYPE +#if defined(Q_COMPILER_DECLTYPE) && defined(Q_COMPILER_AUTO_FUNCTION) template auto run(Functor functor) -> typename QtPrivate::QEnableIf::Value, QFuture >::Type -- cgit v1.2.3