[C++-sig] Problem with vc++ 7
David Abrahams
dave at boost-consulting.com
Thu Nov 21 05:16:01 CET 2002
"Paul F. Kunz" <Paul_Kunz at SLAC.Stanford.EDU> writes:
>>>>>> On Tue, 19 Nov 2002 12:00:20 -0500, David Abrahams <dave at boost-consulting.com> said:
>
>> "Paul F. Kunz" <Paul_Kunz at SLAC.Stanford.EDU> writes:
>>> Environment: boost 1.28.0, VC++ 7.0, Windows 2000 and XP.
>>>
>>> My Python extension module fails to intialize. From the function
>>> generated by the macro
>>>
>>> BOOST_PYTHON_MODULE_INIT(hippo)
>>>
>>> the assertion in BOOST_FUNCTION_FUNCTION::operator()
>>>
>>> assert(!this->empty());
>>>
>>> fails. With same source code, I do not have the problem with gcc
>>> 2.95.3 with boost 1.25.0 or gcc 3.2 with boost 1.28.0 under RedHat
>>> Linux. Also didn't have the problem with VC++ 6.0 sp 5.
>>>
>>> Any clues? Known problem?
>
>> Sorry, nope.
>
>> I can only suggest an upgrade to a current Boost.Python v2. It's
>> much better tested than 1.28.0.
>
> I took your suggestion. I converted to Boost.Python v2 first under
> Linux, and got things working. Then I tried Windows again. Got a
> little further...
>
>>>> from hippo import *
>>>> app = HDApp()
>
> Then I get the same exception as above. Relavent code is...
>
> class_ < PyApp > ( "HDApp" )
> .def ( "canvas", &PyApp::currentCanvas,
> return_value_policy < reference_existing_object > () )
> .def ( "openDocument", &PyApp::openDocument )
> ;
>
> i.e. calling the default constructor causes exception.
That looks like a different problem than the previous one.
Can you post a complete, minimal reproducible test case?
--
David Abrahams
dave at boost-consulting.com * http://www.boost-consulting.com
Boost support, enhancements, training, and commercial distribution
More information about the Cplusplus-sig
mailing list