[Dev-C++] std:auto_ptr compiling error
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Jose S. <joe...@gm...> - 2005-05-20 14:05:06
|
Hi, been getting a problem when compiling some of my code, that I can't=20
understand, Can anybody help me out.
the code where the error occurs is the following:
AAAReturnCode=20
SwigDirector_AAA_ClientAuthSession::TxDelivery(std::auto_ptr<AAAMessage >=
=20
msg) {
AAAReturnCode result ;
jlong jresult =3D 0 ;
std::auto_ptr<AAAMessage > *argp1 ;
std::auto_ptr<AAAMessage > *argp10 ;
JNIEnv * jenv =3D (JNIEnv *) NULL ;
jlong jmsg ;
AAAReturnCode *argp ;
jenv =3D swig_acquire_jenv();
if (!swig_override[1]) {
return AAA_Session<AAA_AuthSessionAttributes >::TxDelivery(msg);
}
Here=3D> *((std::auto_ptr<AAAMessage > *)&jmsg) =3D &msg;
jresult =3D (jlong) jenv->CallStaticLongMethod(Swig::jclass_exampleJNI,=20
Swig::director_methids[1], swig_get_self(), jmsg);
if (jenv->ExceptionOccurred()) return result;
argp =3D *(AAAReturnCode **)&jresult;=20
if (!argp) {
SWIG_JavaThrowException(jenv, SWIG_JavaNullPointerException, "Attempt to=20
dereference null AAAReturnCode");
return result;
}
result =3D *argp;=20
return result;
}
the compiler gives me this:
example_wrap.cxx: In member function `virtual AAAReturnCode
SwigDirector_AAA_ClientAuthSession::TxDelivery(std::auto_ptr<AAAMessage>)':
example_wrap.cxx:228: no match for `std::auto_ptr<AAAMessage>& =3D
std::auto_ptr<AAAMessage>*' operator
/usr/include/c++/3.2.3/memory:228: candidates are: std::auto_ptr<_Tp>&
std::auto_ptr<_Tp>::operator=3D(std::auto_ptr<_Tp>&) [with _Tp =3D AAAMessa=
ge]
/usr/include/c++/3.2.3/memory:350: std::auto_ptr<_Tp>&
std::auto_ptr<_Tp>::operator=3D(std::auto_ptr_ref<_Tp>) [with _Tp =3D
AAAMessage]
thanks=20
Jose
|