diff options
author | Ville Voutilainen <ville.voutilainen@qt.io> | 2018-02-28 20:00:18 +0200 |
---|---|---|
committer | Ville Voutilainen <ville.voutilainen@qt.io> | 2018-03-01 07:52:49 +0000 |
commit | c65fca734c7f13d55e9baa4e4dc7c3f69cb47228 (patch) | |
tree | 27af7cf2bce912cb60267607e4c6e36a88395800 | |
parent | d458bd47106dd849e6cf72b97a27f871735e4eed (diff) | |
download | qtlocation-c65fca734c7f13d55e9baa4e4dc7c3f69cb47228.tar.gz |
Silence a GCC 8 warning in qquickgeocoordinateanimation
qtlocation/src/imports/positioning/qquickgeocoordinateanimation.cpp:278:106: error: cast between incompatible function types from ‘QVariant (*)(const QGeoCoordinate&, const QGeoCoordinate&, qreal)’ {aka ‘QVariant (*)(const QGeoCoordinate&, const QGeoCoordinate&, double)’} to ‘QVariantAnimation::Interpolator’ {aka ‘QVariant (*)(const void*, const void*, double)’} [-Werror=cast-function-type]
d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(&q_coordinateWestInterpolator);
Change-Id: If8728c01782177aeeb0f64a8637093d0c4c4ee2d
Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
-rw-r--r-- | src/imports/positioning/qquickgeocoordinateanimation.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/imports/positioning/qquickgeocoordinateanimation.cpp b/src/imports/positioning/qquickgeocoordinateanimation.cpp index 41c1be1e..b00f187d 100644 --- a/src/imports/positioning/qquickgeocoordinateanimation.cpp +++ b/src/imports/positioning/qquickgeocoordinateanimation.cpp @@ -275,14 +275,14 @@ void QQuickGeoCoordinateAnimation::setDirection(QQuickGeoCoordinateAnimation::Di d->m_direction = direction; switch (direction) { case West: - d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(&q_coordinateWestInterpolator); + d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(reinterpret_cast<void *>(&q_coordinateWestInterpolator)); break; case East: - d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(&q_coordinateEastInterpolator); + d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(reinterpret_cast<void *>(&q_coordinateEastInterpolator)); break; case Shortest: default: - d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(&q_coordinateShortestInterpolator); + d->interpolator = reinterpret_cast<QVariantAnimation::Interpolator>(reinterpret_cast<void *>(&q_coordinateShortestInterpolator)); break; } emit directionChanged(); |