summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-02-10 12:27:45 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-02-11 07:00:45 +0100
commit9e03f6820417c9fcda27b49d9fa5a464f1255c84 (patch)
tree2736cfcb5fee7b0d397581faf380efc589155eb7 /include
parent7df04009b98165f89c89f1e506ebafd2fecc8f5a (diff)
loplugin:indentation in lingucomponent..tools
Change-Id: I96ed4c51ce3fe45c1cb69a7d7ff917f1e152462e Reviewed-on: https://gerrit.libreoffice.org/67607 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include')
-rw-r--r--include/tools/solar.h41
1 files changed, 25 insertions, 16 deletions
diff --git a/include/tools/solar.h b/include/tools/solar.h
index 9ee55c4ad5de..5ea3be835525 100644
--- a/include/tools/solar.h
+++ b/include/tools/solar.h
@@ -55,16 +55,19 @@ inline sal_uInt32 SVBT32ToUInt32 ( const SVBT32 p ) { return static_cast<sal_uIn
+ (static_cast<sal_uInt32>(p[2]) << 16)
+ (static_cast<sal_uInt32>(p[3]) << 24)); }
#if defined OSL_LITENDIAN
-inline double SVBT64ToDouble( const SVBT64 p ) { double n;
- reinterpret_cast<sal_uInt8*>(&n)[0] = p[0];
- reinterpret_cast<sal_uInt8*>(&n)[1] = p[1];
- reinterpret_cast<sal_uInt8*>(&n)[2] = p[2];
- reinterpret_cast<sal_uInt8*>(&n)[3] = p[3];
- reinterpret_cast<sal_uInt8*>(&n)[4] = p[4];
- reinterpret_cast<sal_uInt8*>(&n)[5] = p[5];
- reinterpret_cast<sal_uInt8*>(&n)[6] = p[6];
- reinterpret_cast<sal_uInt8*>(&n)[7] = p[7];
- return n; }
+inline double SVBT64ToDouble( const SVBT64 p )
+{
+ double n;
+ reinterpret_cast<sal_uInt8*>(&n)[0] = p[0];
+ reinterpret_cast<sal_uInt8*>(&n)[1] = p[1];
+ reinterpret_cast<sal_uInt8*>(&n)[2] = p[2];
+ reinterpret_cast<sal_uInt8*>(&n)[3] = p[3];
+ reinterpret_cast<sal_uInt8*>(&n)[4] = p[4];
+ reinterpret_cast<sal_uInt8*>(&n)[5] = p[5];
+ reinterpret_cast<sal_uInt8*>(&n)[6] = p[6];
+ reinterpret_cast<sal_uInt8*>(&n)[7] = p[7];
+ return n;
+}
#else
inline double SVBT64ToDouble( const SVBT64 p ) { double n;
reinterpret_cast<sal_uInt8*>(&n)[0] = p[7];
@@ -78,12 +81,18 @@ inline double SVBT64ToDouble( const SVBT64 p ) { double n;
return n; }
#endif
-inline void ShortToSVBT16( sal_uInt16 n, SVBT16 p ) { p[0] = static_cast<sal_uInt8>(n);
- p[1] = static_cast<sal_uInt8>(n >> 8); }
-inline void UInt32ToSVBT32 ( sal_uInt32 n, SVBT32 p ) { p[0] = static_cast<sal_uInt8>(n);
- p[1] = static_cast<sal_uInt8>(n >> 8);
- p[2] = static_cast<sal_uInt8>(n >> 16);
- p[3] = static_cast<sal_uInt8>(n >> 24); }
+inline void ShortToSVBT16( sal_uInt16 n, SVBT16 p )
+{
+ p[0] = static_cast<sal_uInt8>(n);
+ p[1] = static_cast<sal_uInt8>(n >> 8);
+}
+inline void UInt32ToSVBT32 ( sal_uInt32 n, SVBT32 p )
+{
+ p[0] = static_cast<sal_uInt8>(n);
+ p[1] = static_cast<sal_uInt8>(n >> 8);
+ p[2] = static_cast<sal_uInt8>(n >> 16);
+ p[3] = static_cast<sal_uInt8>(n >> 24);
+}
#if defined OSL_LITENDIAN
inline void DoubleToSVBT64( double n, SVBT64 p ) { p[0] = reinterpret_cast<sal_uInt8*>(&n)[0];
p[1] = reinterpret_cast<sal_uInt8*>(&n)[1];