Le 13 sept. 2011 à 14:42, Guillaume Lazzara a écrit :
[...]
diff --git a/milena/mln/core/concept/function.hh
b/milena/mln/core/concept/function.hh
index 5b6c15a..22e338e 100644
--- a/milena/mln/core/concept/function.hh
+++ b/milena/mln/core/concept/function.hh
@@ -76,7 +76,7 @@ namespace mln
Apple's llvm-gcc has a bug causing memmove() errors if the copy
constructor is not declared along with operator=(). */
- Function& operator=(const Function&);
+ Function<E>& operator=(const Function<E>&);
};
Actually, you should have updated ctors as well if you wanted to be truly
``consistent''.
And more: other classes of this file as well! :-)
The parameter list is not required within the declaration of a template class, and the
declaration of Function<E> was perfectly valid before your change. Given this, plus
the
fact that changing other names is time-consuming and painful, I suggest we use
non-parameterized names within class declarations (and in the present case, revert this
very change).
@@ -231,7 +231,7 @@ namespace mln
template <typename E>
inline
Function<E>&
- Function<E>::operator=(const Function&)
+ Function<E>::operator=(const Function<E>&)
{
return *this;
}
On the other hand, that change on the *definition* of operator= makes more sense (even
if the parameter is optional for the argument type), so I think we can keep it.