Re: DIP64 - Regarding 'pure' and 'nothrow'

2014-08-28 Thread Aerolite via Digitalmars-d-learn
On Wednesday, 27 August 2014 at 20:17:11 UTC, Brian Schott wrote: It would be nice if we could at least allow both "nothrow" and "@nothrow". Because "nothrow" is already a keyword there's no possibility of a UDA overriding it. This would at least give people the option of making their code look

DIP64 - Regarding 'pure' and 'nothrow'

2014-08-27 Thread Aerolite via Digitalmars-d-learn
Hey all, I just read the wiki article on DIP64 - http://wiki.dlang.org/DIP64 The discrepancy between the annotation-style attributes such as '@safe', '@property', etc and the keyword attributes 'pure' and 'nothrow' has always really bugged me ever since I started using D. How likely is it that

Re: Why no multiple-dispatch?

2014-08-27 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 17:16:10 UTC, Idan Arye wrote: This CAN NOT BE DONE at compile-time, since the compiler doesn't know at compile time the exact subclass of the instance it'll get at runtime. To clarify: I'm not talking about the creation of the multi-method mechanism - which *can* b

Re: Why no multiple-dispatch?

2014-08-25 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 08:45:15 UTC, Ola Fosheim Grøstad wrote: However, why do you want multiple dispatch? I cannot think of any application level use scenario where you have two class hierarchies that you have no control over. So I don't really see the value of multiple dispatch in a sy

Re: Why no multiple-dispatch?

2014-08-25 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 07:36:22 UTC, Idan Arye wrote: If multi-dispatching is done at compile-time, it can't rely on the object's runtime type - only on the static type of the reference that holds it. This is no different than regular function overloading that we already have. Well any

Re: Why no multiple-dispatch?

2014-08-24 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 01:34:14 UTC, Idan Arye wrote: On Monday, 25 August 2014 at 01:10:32 UTC, Aerolite wrote: -- No syntax modification (unless you want the feature to be optional) If this ever gets into the core language, it absolutely must be optional! Think of the implications of

Re: Why no multiple-dispatch?

2014-08-24 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 00:42:41 UTC, Idan Arye wrote: Speaking of library solutions, I checked with my `castSwitch` PR and it managed to implement single-argument multi-dispatch: https://github.com/D-Programming-Language/phobos/pull/1266#issuecomment-53217374 I'll try to get it to suppor

Re: Why no multiple-dispatch?

2014-08-24 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 00:08:25 UTC, Jonathan M Davis wrote: At this point, if something can be implemented in a library rather than in the language, the odds are low that it will be solved in the language. The language is very powerful and already a bit complicated, so usually the resp

Re: Why no multiple-dispatch?

2014-08-24 Thread Aerolite via Digitalmars-d-learn
On Monday, 25 August 2014 at 00:20:26 UTC, Vladimir Panteleev wrote: On Sunday, 24 August 2014 at 23:42:51 UTC, Aerolite wrote: So what seems to be the situation here? Hi Aerolite, I've never used multiple dispatch in any language, but from looking at the C# syntax here[1]: ReactSpecializ

Why no multiple-dispatch?

2014-08-24 Thread Aerolite via Digitalmars-d-learn
Hey all, I was surprised to learn yesterday that D does not actually support Multiple-Dispatch, also known as Multimethods. Why is this? Support for this feature is already present in Scala, C# 4.0, Groovy, Clojure, etc... Would it not make sense for D to remain competitive in this regard? While

Opinions: The Best and Worst of D (for a lecture/talk I intend to give)

2014-07-07 Thread Aerolite via Digitalmars-d-learn
Hey all, I've not posted here in a while, but I've been keeping up to speed with D's progress over the last couple of years and remain consistently impressed with the language. I'm part of a new computing society in the University of Newcastle, Australia, and am essentially known throughout