On Tuesday, 12 June 2018 at 14:33:57 UTC, Steven Schveighoffer
wrote:
On 6/12/18 9:04 AM, Jacob Shtokolov wrote:
[...]
I'll respond to say that I don't know a lot of people who use
signals and slots. It's a very old part of Phobos, and I think
a lot of people here aren't familiar with it.
[...]
I've never heard of this functionality. Looking it up, it's not
used anywhere in druntime, only from phobos, and only from this
std.signals implementation (literally a search through all code
finds the function rt_attachDisposeEvent in 2 places -- the
definition, and the one usage in std.signals).
Looking at the implementation, it depends on having an Object
with a Monitor, as the event is stored in the monitor. So you
couldn't attach it to any specific piece of memory, it HAS to
be an Object.
But like I said, it's not used pretty much anywhere. So I think
nobody would miss it if you ripped it out and made it better :)
feel free to open a bug report and/or PR and get some more
discussion going.
-Steve
Thank you Steve!
Then I'll try to fire a bug report and propose my own solution to
this problem.
Probably there is no need to track down the non-object dispose
events.
Good to hear that not so many people are affected by this 😏