$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Ronald Garcia (garcia_at_[hidden])
Date: 2002-10-31 09:49:55
On Thu, 31 Oct 2002, Toon Knapen wrote:
> to make the test-program compile on IBM/VisualAge.
>
> I've just put the equal function to compare two int's before the templated
> equal (intended for matrices) sine the former is used in the latter
> (should'nt have compiled on other platforms neither IMO)
>
>
Thank you for the patch.  I will apply it sometime today. I think the
problem is actually a compiler bug.  The call to
equal is not bound until the template is instantiated, or at least that's
my understanding of it.
cheers,
ron
>
> Index: assign.cpp
> ===================================================================
> RCS file: /cvsroot/boost/boost/libs/multi_array/test/assign.cpp,v
> retrieving revision 1.2
> diff -u -r1.2 assign.cpp
> --- assign.cpp  14 Aug 2002 22:29:36 -0000      1.2
> +++ assign.cpp  31 Oct 2002 10:04:06 -0000
> @@ -9,6 +9,11 @@
>  #include <algorithm>
>  #include <iostream>
>
> +bool equal(const int& a, const int& b)
> +{
> +  return a == b;
> +}
> +
>  template <typename ArrayA, typename ArrayB>
>  bool equal(const ArrayA& A, const ArrayB& B)
>  {
> @@ -18,11 +23,6 @@
>      if (!equal(*ia, *ib))
>        return false;
>    return true;
> -}
> -
> -bool equal(const int& a, const int& b)
> -{
> -  return a == b;
>  }
> _______________________________________________
> Unsubscribe & other changes: http://listarchives.boost.org/mailman/listinfo.cgi/boost
>