D16863: Removed old-style casting warnings

Yuri Chornoivan noreply at phabricator.kde.org
Tue Nov 13 12:41:35 GMT 2018


yurchor added inline comments.

INLINE COMMENTS

> sprite.cpp:59
>  	QTransform transform = QTransform::fromTranslate(
> -		renderer()->defaultSize().width()  * cos((degrees-135) * M_PI/180) * sqrt((double)2.0)/2,
> -		renderer()->defaultSize().height() * sin((degrees-135) * M_PI/180) * sqrt((double)2.0)/2
> +        renderer()->defaultSize().width()  * cos((degrees-135) * M_PI/180) * sqrt(static_cast<double>(2.0))/2,
> +        renderer()->defaultSize().height() * sin((degrees-135) * M_PI/180) * sqrt(static_cast<double>(2.0))/2

This might be a stupid question but isn't it enough to write just

  sqrt(2.0)

or

  sqrt(2.0L)

?
Thanks in advance for your answers.

REPOSITORY
  R337 KTurtle

REVISION DETAIL
  https://phabricator.kde.org/D16863

To: msuarez, tcanabrava, rizzitello
Cc: yurchor, kde-edu, narvaez, apol
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-edu/attachments/20181113/55fcbaab/attachment.html>


More information about the kde-edu mailing list