[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance
From: |
Jaroslav Hajek |
Subject: |
Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop" |
Date: |
Fri, 20 Aug 2010 21:27:47 +0200 |
On Fri, Aug 20, 2010 at 3:43 PM, RUSS BRENNAN <address@hidden> wrote:
> Ok I looked into this a bit more and I think I understand the problem.
> Around line 57 of intNDArray.cc, we have
>
> template <class T>
> bool
> intNDArray<T>::any_element_not_one_or_zero (void) const {
> octave_idx_type nel = this->nelem ();
> for (octave_idx_type i = 0; i < nel; i++)
> {
> T val = this->elem (i);
> if (val != 0.0 && val != 1.0)
> return true;
> }
> return false;
> }
>
> While the declaration of the != operator matches:
>
> function template "bool octave_int_cmp_op::mop<xop,T>(T,
> double)"
> function template "bool
> octave_int_cmp_op::mop<xop>(int64_t={long long}, double)"
>
> Which means that if in the case that T=int64_t, the two declarations are the
> same, which would obviously cause some compiler issues.
No, the compiler should resolve this, because the second overload is
more specialized. You need to read the C++ standard carefully to
understand. This has been seen before with gcc 3, see
http://octave.1599824.n4.nabble.com/Cast-ambiguity-compilation-error-td1653304.html#a1653307
I'm very surprised that your Intel C++ behaves differently from mine.
Forgive me the stupid question, but are you sure you properly upgraded
and are really calling 11.0 (try icpc --version)?
As another desperate attempt, you may try the development sources.
--
RNDr. Jaroslav Hajek, PhD
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz
- Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/16
- Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", Jaroslav Hajek, 2010/08/18
- RE: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/18
- Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop",
Jaroslav Hajek <=
- RE: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/22
- Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", Jaroslav Hajek, 2010/08/23
- RE: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/23
- RE: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/24
- Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", Jaroslav Hajek, 2010/08/25
- RE: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", RUSS BRENNAN, 2010/08/31
- Re: Compiling Octave 3.2.3 with icpc 10.1 fails: more than one instance of overloaded function "octave_int_cmp_op::mop", Jaroslav Hajek, 2010/08/20