Boost logo

Boost Users :

From: a_hao_at_[hidden]
Date: 2004-11-16 22:48:29


>> Hi,
>>
>> I tried the signals, the code below will crash
>>
>> #include <boost/signal.hpp>
>> int _tmain(int argc, _TCHAR* argv[])
>> {
>> boost::signal<int(int)> _sig;
>> _sig(10);
>>
>> return 0;
>> }
>>
>> but code below works well
>>
>> #include <boost/signal.hpp>
>> int _tmain(int argc, _TCHAR* argv[])
>> {
>> boost::signal<void(int)> _sig;
>> _sig(10);
>>
>> return 0;
>> }
>>
>> The only difference is one has return value, the other doesn't, is
>> this a bug or by design?
>
>Sounds like a bug... could you give us more information? Compiler,
>platform, Boost version, etc.
>
> Doug
>

I'm using win2000 pro build 5.00.2195 service pack4, Visual Studio 2003 version 7.1.3091, boost v1_31_0.
And I also tested this using boost v1_32_0, also has this bug.

Before crash, this assert will fail: "Assertion failed: first != last, file d:\boost_1_31_0\boost\last_value.hpp, line 23"

Thanks,
Wang Yun


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net