summaryrefslogtreecommitdiff
path: root/include/tools
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-04-06 13:42:59 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-04-07 07:07:40 +0000
commit26e7c6d6abf889a7e5bbc0fa4f73034f9cbd07b9 (patch)
tree2a47812e7598234339f34671369ecf07db65ed8b /include/tools
parent8e9b4227b739d735a4c232a5f0e7df47a4e94be9 (diff)
loplugin:redundantcast check for c-style char casts
Change-Id: Id6881262e370fd563ec29db95e4af5cfcb04ea34 Reviewed-on: https://gerrit.libreoffice.org/36247 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/tools')
-rw-r--r--include/tools/vcompat.hxx13
1 files changed, 8 insertions, 5 deletions
diff --git a/include/tools/vcompat.hxx b/include/tools/vcompat.hxx
index 71b64beef916..0adf6913ea86 100644
--- a/include/tools/vcompat.hxx
+++ b/include/tools/vcompat.hxx
@@ -21,11 +21,14 @@
#include <tools/toolsdllapi.h>
-#define COMPAT_FORMAT( char1, char2, char3, char4 ) \
- ((sal_uInt32)((((sal_uInt32)(char)(char1)))| \
- (((sal_uInt32)(char)(char2))<<8UL)| \
- (((sal_uInt32)(char)(char3))<<16UL)| \
- ((sal_uInt32)(char)(char4))<<24UL))
+inline sal_uInt32 COMPAT_FORMAT( char char1, char char2, char char3, char char4 )
+{
+ return
+ ((sal_uInt32)char1) |
+ (((sal_uInt32)char2) << 8) |
+ (((sal_uInt32)char3) << 16) |
+ (((sal_uInt32)char4) << 24);
+};
class SvStream;
enum class StreamMode;