[Libreoffice-commits] core.git: sc/inc

Stephan Bergmann sbergman at redhat.com
Tue Mar 4 23:57:30 PST 2014


 sc/inc/stlalgorithm.hxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 4ce261f9f68ee710a883604181299b13cd14ae7b
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Wed Mar 5 08:56:57 2014 +0100

    Avoid bogus MSVC 2012 (at least) "unreferenced formal parameter" warning
    
    Change-Id: I3c1243e449e0b7851e415cf7543483d16c5ac7ec

diff --git a/sc/inc/stlalgorithm.hxx b/sc/inc/stlalgorithm.hxx
index bda11bf..19945c2 100644
--- a/sc/inc/stlalgorithm.hxx
+++ b/sc/inc/stlalgorithm.hxx
@@ -62,7 +62,11 @@ public:
     AlignedAllocator(const AlignedAllocator<_Type2,_Alignment>&) {}
 
     void construct(T* p, const value_type& val) { new(p) value_type(val); }
-    void destroy(T* p) { p->~value_type(); }
+    void destroy(T* p)
+    {
+        p->~value_type();
+        (void)p; // avoid bogus MSVC '12 "unreferenced formal parameter" warning
+    }
 
     size_type max_size() const
     {


More information about the Libreoffice-commits mailing list