summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-09-15 17:06:07 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-09-15 17:12:07 +0200
commitc94f43c9da74dbcc12f35e13b64c68c54be35421 (patch)
tree9e88bec68060ccb4ec18b6c61e87c9fdbcc8c680 /include
parentCppunitTest_sw_uiwriter: sal_Bool -> bool (diff)
downloadcore-c94f43c9da74dbcc12f35e13b64c68c54be35421.tar.gz
core-c94f43c9da74dbcc12f35e13b64c68c54be35421.zip
Mark o3tl::heap_ptr as SAL_WARN_UNUSED
...to make it more straightforward to fix blunder as in a88b2d841856026ea1a0539d670e07fafd296c6e "Resolves: fdo#81039 crash on adding new macro library." Conceivably, instances of heap_ptr could legitimately be created only for ctor/ dtor effect, but then again uses of heap_ptr should arguably be replaced with std::unique_ptr anyway. Change-Id: I9c765b8d265f3c26d459ec276e335eeebc8fee91
Diffstat (limited to 'include')
-rw-r--r--include/o3tl/heap_ptr.hxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/o3tl/heap_ptr.hxx b/include/o3tl/heap_ptr.hxx
index 4a7e3683f68d..eca82a7c692d 100644
--- a/include/o3tl/heap_ptr.hxx
+++ b/include/o3tl/heap_ptr.hxx
@@ -23,7 +23,7 @@
#include <boost/assert.hpp>
#include <boost/checked_delete.hpp>
-
+#include <sal/types.h>
namespace o3tl
{
@@ -72,7 +72,7 @@ namespace o3tl
complain.
*/
template <class T, class Deleter = boost::checked_deleter<T> >
-class heap_ptr
+class SAL_WARN_UNUSED heap_ptr
{
public:
typedef T element_type; /// Provided for generic programming.