summaryrefslogtreecommitdiff
path: root/basic
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-04-06 08:59:07 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-04-06 07:47:30 +0000
commit7662e92c64ec194a2089f633a363d9dc45a4aa9d (patch)
tree1086154f31c0c9c6386b44ab83bd382f5308df8c /basic
parent823a8f3117a8be1de92168226f561ed804db3e93 (diff)
loplugin:redundantcast find cstyle double casts
Change-Id: I5507be190dac781e5cdb545a60acf3d50056c9f8 Reviewed-on: https://gerrit.libreoffice.org/36187 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basic')
-rw-r--r--basic/source/runtime/methods.cxx4
-rw-r--r--basic/source/runtime/methods1.cxx2
-rw-r--r--basic/source/sbx/sbxdate.cxx2
-rw-r--r--basic/source/sbx/sbxdbl.cxx4
4 files changed, 6 insertions, 6 deletions
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 6344bdebaf6b..e23536751753 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -2370,7 +2370,7 @@ double Now_Impl()
nSeconds *= 3600;
nSeconds += aTime.GetMin() * 60;
nSeconds += aTime.GetSec();
- double nDays = ((double)nSeconds) / (double)(24.0*3600.0);
+ double nDays = ((double)nSeconds) / (24.0*3600.0);
aSerial += nDays;
return aSerial;
}
@@ -3254,7 +3254,7 @@ RTLFUNC(FileDateTime)
nSeconds *= 3600;
nSeconds += aTime.GetMin() * 60;
nSeconds += aTime.GetSec();
- double nDays = ((double)nSeconds) / (double)(24.0*3600.0);
+ double nDays = ((double)nSeconds) / (24.0*3600.0);
fSerial += nDays;
Color* pCol;
diff --git a/basic/source/runtime/methods1.cxx b/basic/source/runtime/methods1.cxx
index c14281c4ea96..f38d47a882bf 100644
--- a/basic/source/runtime/methods1.cxx
+++ b/basic/source/runtime/methods1.cxx
@@ -627,7 +627,7 @@ void Wait_Impl( bool bDurationBased, SbxArray& rPar )
{
double dWait = rPar.Get(1)->GetDouble();
double dNow = Now_Impl();
- double dSecs = (double)( ( dWait - dNow ) * (double)( 24.0*3600.0) );
+ double dSecs = ( dWait - dNow ) * 24.0 * 3600.0;
nWait = (long)( dSecs * 1000 ); // wait in thousands of sec
}
else
diff --git a/basic/source/sbx/sbxdate.cxx b/basic/source/sbx/sbxdate.cxx
index ac098881395a..76b9c7306fa2 100644
--- a/basic/source/sbx/sbxdate.cxx
+++ b/basic/source/sbx/sbxdate.cxx
@@ -413,7 +413,7 @@ start:
break;
case SbxBYREF | SbxDATE:
case SbxBYREF | SbxDOUBLE:
- *p->pDouble = (double) n;
+ *p->pDouble = n;
break;
case SbxBYREF | SbxCURRENCY:
if( n > SbxMAXCURR )
diff --git a/basic/source/sbx/sbxdbl.cxx b/basic/source/sbx/sbxdbl.cxx
index cfe964097ad7..3c17e6155ef7 100644
--- a/basic/source/sbx/sbxdbl.cxx
+++ b/basic/source/sbx/sbxdbl.cxx
@@ -198,7 +198,7 @@ start:
case SbxLPSTR:
if( !p->pOUString )
p->pOUString = new OUString;
- ImpCvtNum( (double) n, 14, *p->pOUString, bCoreString );
+ ImpCvtNum( n, 14, *p->pOUString, bCoreString );
break;
case SbxOBJECT:
{
@@ -295,7 +295,7 @@ start:
*p->puInt64 = ImpDoubleToSalUInt64( n ); break;
case SbxBYREF | SbxDATE:
case SbxBYREF | SbxDOUBLE:
- *p->pDouble = (double) n; break;
+ *p->pDouble = n; break;
case SbxBYREF | SbxCURRENCY:
if( n > SbxMAXCURR )
{