Re: [sigc] Clarifying the behavior of sigc::slot_base::operator bool
- From: Daniel Elstner <daniel kitta googlemail com>
- To: James Lin <jameslin vmware com>
- Cc: "libsigc-list gnome org" <libsigc-list gnome org>
- Subject: Re: [sigc] Clarifying the behavior of sigc::slot_base::operator bool
- Date: Tue, 20 Oct 2009 15:09:16 +0200
Am Mittwoch, den 23.09.2009, 17:27 -0700 schrieb James Lin:
> Hello,
>
> What should the expected output be for:
>
> void bar(void) { }
>
> sigc::slot<void> foo = sigc::ptr_fun(&bar);
> foo = sigc::slot<void>();
>
> std::cout << bool(foo) << std::endl;
>
This looks like a bug to me. At least if
sigc::slot<void> foo;
std::cout << bool(foo) << std::endl;
outputs 0 instead.
--Daniel
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]