olena: olena-2.0-856-gaac38bd Address Clang warnings in Swilena.

* dynamic_image2d.i: Here. --- swilena/ChangeLog | 6 ++++++ swilena/dynamic_image2d.i | 25 +++++++++++++++++-------- 2 files changed, 23 insertions(+), 8 deletions(-) diff --git a/swilena/ChangeLog b/swilena/ChangeLog index fcd4fd9..aeb9f6b 100644 --- a/swilena/ChangeLog +++ b/swilena/ChangeLog @@ -1,3 +1,9 @@ +2014-05-22 Roland Levillain <roland@lrde.epita.fr> + + Address Clang warnings in Swilena. + + * dynamic_image2d.i: Here. + 2013-09-10 Roland Levillain <roland@lrde.epita.fr> Swilena: Remove lines `VARIABLE = @VARIABLE@' from Makefile.am's. diff --git a/swilena/dynamic_image2d.i b/swilena/dynamic_image2d.i index 532f1e0..2a0430d 100644 --- a/swilena/dynamic_image2d.i +++ b/swilena/dynamic_image2d.i @@ -1,5 +1,6 @@ // -*- C++ -*- -// Copyright (C) 2008, 2009 EPITA Research and Development Laboratory (LRDE) +// Copyright (C) 2008, 2009, 2014 EPITA Research and Development +// Laboratory (LRDE). // // This file is part of Olena. // @@ -152,7 +153,7 @@ namespace mln /// 3). dynamic_image2d(const box2d& b); - // FIXME: Add a virtual dtor? + virtual ~dynamic_image2d(); /// Initialize an empty image. virtual void init_(const box2d& b); @@ -230,6 +231,12 @@ namespace mln template <typename T> inline + dynamic_image2d<T>::~dynamic_image2d() + { + } + + template <typename T> + inline void dynamic_image2d<T>::init_(const box2d& b) { @@ -258,10 +265,11 @@ namespace mln template <typename T> inline const T& - dynamic_image2d<T>::operator()(const point2d& p) const + dynamic_image2d<T>::operator()(const point2d&) const { - // Dummy. - assert(false); + abort(); + static T v; + return v; } // Dummy implementation, provided to have swig wrap the class (swig won't @@ -269,10 +277,11 @@ namespace mln template <typename T> inline T& - dynamic_image2d<T>::operator()(const point2d& p) + dynamic_image2d<T>::operator()(const point2d&) { - // Dummy. - assert(false); + abort(); + static T v; + return v; } template <typename T> -- 1.7.10.4
participants (1)
-
Roland Levillain