-#
-# TODO: Obsolete. Remove and clean source.
-# Versions of GCC before 3.0 had a problem with the explicit
-# instantiation of member templates when the member was in fact
-# an operator. In that case, they needed the "template" keyword,
-# which is actually not allowed at this place. Test case is
-#
-# struct X
-# {
-# template <typename T2>
-# X operator = (T2 &) { return X(); };
-# };
-#
-# template X X::operator=<float> (float &);
-#
-# The compiler only groks this if the "operator=" is prepended
-# by "template". We detect this, and either set the
-# DEAL_II_MEMBER_OP_TEMPLATE_INST to "template" or nothing, so
-# that it gets expanded to the right string needed in this place.
-#
-CHECK_CXX_SOURCE_COMPILES(
- "
- struct X
- {
- template <typename T2>
- X operator = (T2 &) { return X(); }
- };
-
- template X X::operator=<float> (float &);
- int main(){return 0;}
- "
- DEAL_II_MEMBER_OP_TEMPLATE_INST_OK)
-
-IF(DEAL_II_MEMBER_OP_TEMPLATE_INST_OK)
- SET(DEAL_II_MEMBER_OP_TEMPLATE_INST "")
-ELSE()
- SET(DEAL_II_MEMBER_OP_TEMPLATE_INST "template")
-ENDIF()
-
-
-
#
# Some compiler versions, notably ICC, have trouble with the
# following code in which we explicitly call a destructor.
* Configured in check_for_compiler_bugs: *
******************************************/
-/* Define if we have to work around a bug in gcc with explicitly
- * instantiating template member operators. See the aclocal.m4 file in the
- * top-level directory for a description of this bug.
- */
-#define DEAL_II_MEMBER_OP_TEMPLATE_INST @DEAL_II_MEMBER_OP_TEMPLATE_INST@
-
/* Define if we have to work around a bug where the compiler doesn't accept
* an explicit destructor call. See the aclocal.m4 file in the top-level
* directory for a description of this bug.
{
template
bool
- Vector<S1>::DEAL_II_MEMBER_OP_TEMPLATE_INST
- operator==<S2>(const Vector<S2>&) const;
+ Vector<S1>::operator==<S2>(const Vector<S2>&) const;
template
S1
- Vector<S1>::DEAL_II_MEMBER_OP_TEMPLATE_INST
- operator*<S2>(const Vector<S2>&) const;
+ Vector<S1>::operator*<S2>(const Vector<S2>&) const;
template
void Vector<S1>::reinit<S2>(const Vector<S2>&, const bool);
}
{
template
bool
- Vector<S1>::DEAL_II_MEMBER_OP_TEMPLATE_INST
- operator==<S2>(const Vector<S2>&) const;
+ Vector<S1>::operator==<S2>(const Vector<S2>&) const;
template
S1
- Vector<S1>::DEAL_II_MEMBER_OP_TEMPLATE_INST
- operator*<S2>(const Vector<S2>&) const;
+ Vector<S1>::operator*<S2>(const Vector<S2>&) const;
template
void Vector<S1>::reinit<S2>(const Vector<S2>&, const bool);
}