Utils: fix QtConcurrent::run(std::function)

The std::function template parameter must be the same for run
and StoredInterfaceFunctionCall0. Otherwise gcc 4.9.1-19 yields
errors.

Change-Id: I9d4af89320cebd33451d5643ec3d7af08595a786
Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
This commit is contained in:
Joerg Bornemann
2015-02-16 15:47:43 +01:00
parent cb48e4854a
commit 92b545807f

View File

@@ -424,7 +424,7 @@ QFuture<T> run(void (Class::*fn)(QFutureInterface<T> &, Arg1, Arg2, Arg3, Arg4,
template <typename T>
QFuture<T> run(const std::function<void (QFutureInterface<T> &)> &fn)
{
return (new StoredInterfaceFunctionCall0<T, std::function<void (QFutureInterface<T>)>>(fn))->start();
return (new StoredInterfaceFunctionCall0<T, std::function<void (QFutureInterface<T> &)>>(fn))->start();
}
} // namespace QtConcurrent