What is difference between std.signal and events?
Orvid King
blah38621 at gmail.com
Thu Jan 16 15:22:45 PST 2014
On Thu, 16 Jan 2014 13:43:39 -0600, Uranuz <neuranuz at gmail.com> wrote:
> I have read some posts about new std.signal implementation. The last was
> this review thread:
> http://forum.dlang.org/thread/ujlhznaphepibgtpcoqz@forum.dlang.org. What
> I still can't understand what is difference between signals and events
> in languages like JavaScript, C# and Borland C++ (that has it's own
> extension to language to implement events). As far as I understand in C#
> events are based on delegates but have some limitations. They can only
> be fired from owner's method. In JS events at my point of view are used
> to notify some input events or DOM changes. Borland C++ uses them to
> notify GUI events (in example button click). Is module called "signals"
> only for not interfere with OS IO events or is there some difference and
> reason?
It's called signals because they are addressed by name, and are global in
scope. (provided I've read the information on std.signal correctly) There
are also C#-like multi-cast delegate (event) implementations, such as my
implementation. (https://github.com/Orvid/std.event)
More information about the Digitalmars-d-learn
mailing list