|
Boost : |
From: Sven Johannsen (Sven.Johannsen_at_[hidden])
Date: 2004-07-29 01:36:29
Michael Glassford wrote:
>>
>> with the current cvs-version (7/23/2004) i can't build the thread
>> library with stlport 4.5.3 and msvc60.
>>
>> I use the following bjam command:
>> bjam "-sTOOLS=msvc-stlport" "-sSTLPORT_PATH=D:\develop\STLPort"
>> "-sSTLPORT_VERSION=4.5.3"
>>
>> and get the following errortext:
>> ....\boost-23072004\libs\thread\build\..\src\barrier.cpp(21) : error
>> C2440: 'type cast' : 'char [22]' kann nicht in 'class
>> _STL::invalid_argument' konvertiert werden
>> Quelltyp konnte von keinem Konstruktor angenommen werden, oder
>> die Ueberladungsaufloesung des Konstruktors ist mehrdeutig
>>
>> Sorry about the german error-text. it's something about: can't convert
>> char[22] to 'class _STL::invalid_argument'
>> I don't know that wrong about:
>> throw std::invalid_argument("count cannot be zero.");
>>
>> because the StlPort defines invalid_argument as:
>>
>> class _STLP_CLASS_DECLSPEC invalid_argument : public logic_error {
>> public:
>> invalid_argument(const string& __arg) : logic_error(__arg) {}
>> # ifdef _STLP_OWN_IOSTREAMS
>> ~invalid_argument() _STLP_NOTHROW_INHERENTLY;
>> # endif
>> };
>
>
> Is that the complete definition?
>
yes. there is no explizit or something else.
>> With the microsoft stl everything compile fine. (bjam "-sTOOLS=msvc")
>
>
> Google tells me that this "Quelltyp konnte von keinem Konstruktor
> angenommen werden, oder die Ueberladungsaufloesung des Konstruktors ist
> mehrdeutig"?" translates to "Source type could be accepted by no
> constructor, or the dissolution of overloading of the constructor is
> ambiguous." From this, I would guess either that the invalid_argument
i found the english errortext in the msdn: ()
Compiler Error C2440
'conversion' : cannot convert from 'type1' to 'type2'
> ambiguous." From this, I would guess either that the invalid_argument
> class has another constructor that you didn't show that is making the
> conversion ambiguous, or that the string class either has no constructor
> that takes a single char* argument, or else that constructor is marked
> "explicit", or else there are multiple constructors and the choice
> between them is ambiguous.
>
> Mike
>
the ms-stl defines invalid_argument with explicit and
// CLASS invalid_argument
class invalid_argument : public logic_error {
public:
explicit invalid_argument(const string& _S)
: logic_error(_S) {}
virtual ~invalid_argument()
{}
protected:
virtual void _Doraise() const
{_RAISE(*this); }
};
there must something differend.
does nobody use msvc and stlport and the current boost-version?
Sven
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk