[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Compilation problem MSVC with recent 'sort' implementation
From: |
Michael Goffioul |
Subject: |
Re: Compilation problem MSVC with recent 'sort' implementation |
Date: |
Sun, 3 Feb 2008 13:44:55 +0100 |
On 2/3/08, John W. Eaton <address@hidden> wrote:
> Since the Range class is not used directly in Array.cc, I don't see
> why it needs to be included there. I've removed the #include
> statement.
Unfortunately, this is not enough to make it compilable with
MSVC. At link stage of liboctave, I get duplicated symbols
error (see below). This seems logical to me to have duplicated
symbols as Array-C.cc includes Array.cc and that the assign
instantiation also instantiates Array<double>. However, as
Array-d.cc also perform explicit specialization, I guess the
compiler cannot determine which one it has to export in the
DLL (I also wonder how gcc resolves this).
I don't know how to handle this.
Michael.
Array-d.o : error LNK2005: "bool __cdecl
ascending_compare<double>(double,double)"
(address@hidden@@address@hidden) already defined in Array-C.o
Array-d.o : error LNK2005: "bool __cdecl
ascending_compare<double>(class vec_index<double> *,class
vec_index<double> *)"
(address@hidden@@address@hidden@@address@hidden) already defined in
Array-C.o
Array-d.o : error LNK2005: "bool __cdecl
descending_compare<double>(double,double)"
(address@hidden@@address@hidden) already defined in Array-C.o
Array-d.o : error LNK2005: "bool __cdecl
descending_compare<double>(class vec_index<double> *,class
vec_index<double> *)"
(address@hidden@@address@hidden@@address@hidden) already defined
in Array-C.o
Array-d.o : error LNK2005: "public: class Array<double> __thiscall
Array<double>::sort(int,enum sortmode)const "
(address@hidden@N@@address@hidden@@@Z) already defined in
Array-C.o
Array-d.o : error LNK2005: "public: class Array<double> __thiscall
Array<double>::sort(class Array<int> &,int,enum sortmode)const "
(address@hidden@N@@address@hidden@H@@HW4sortmode@@@Z) already
defined in Array-C.o
- Compilation problem MSVC with recent 'sort' implementation, Michael Goffioul, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, Shai Ayal, 2008/02/03
- Compilation problem MSVC with recent 'sort' implementation, John W. Eaton, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation,
Michael Goffioul <=
- Re: Compilation problem MSVC with recent 'sort' implementation, Michael Goffioul, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, Shai Ayal, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, John W. Eaton, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, Shai Ayal, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, Thomas Treichl, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, John W. Eaton, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, Thomas Treichl, 2008/02/03
- Re: Compilation problem MSVC with recent 'sort' implementation, John W. Eaton, 2008/02/03