std.signal : voting has begun
Denis Shelomovskij
verylonglogin.reg at gmail.com
Wed Jan 15 00:14:51 PST 2014
06.01.2014 13:11, Dicebot пишет:
> Some time ago there have been a review for `std.signal` Phobos proposal
> (http://forum.dlang.org/thread/ujlhznaphepibgtpcoqz@forum.dlang.org#post-ujlhznaphepibgtpcoqz:40forum.dlang.org).
> It have not received much feedback and I was a it too busy to proceed
> with final voting at that moment but with no outstanding issues to
> address nothing prevents that final step.
>
> Let's put 2 week deadline to refresh memories about the proposal and
> make some decision. Voting closes at January 20th 23:59 GMT 0
>
> Please take some time and help make Phobos better ;)
No.
Any signals implementation is at least blocked by the fact closure
delegates lifetime can't be determined (see issues [2] and [3]).
Requirement to explicitly pass owning object is redundant and
unacceptable, such code must work:
---
/// Usage: don't pass struct member function delegates as `del`.
void f(void delegate() del)
{
obj.event.connect(del);
}
---
Yes, I still don't see an elegant way to fix the language for struct
member function delegates, but for closures there is issue [1].
Another way to make things work is a runtime support for weak
references, see druntime pull 639 discussion [4].
Also see this thread for more discussion about signals problems: [5].
[1] https://d.puremagic.com/issues/show_bug.cgi?id=9601
[2] https://d.puremagic.com/issues/show_bug.cgi?id=9602
[3] https://d.puremagic.com/issues/show_bug.cgi?id=9603
[4] https://github.com/D-Programming-Language/druntime/pull/639
[5] http://forum.dlang.org/thread/kkdkh3$sft$1@digitalmars.com
--
Денис В. Шеломовский
Denis V. Shelomovskij
More information about the Digitalmars-d-announce
mailing list