[Fwd: Re: [go-nuts] Re: Generics false dichotomy]

Russel Winder russel at winder.org.uk
Mon Feb 17 14:03:56 PST 2014


On Mon, 2014-02-17 at 21:00 +0100, Paulo Pinto wrote:
> Am 17.02.2014 20:08, schrieb Andrei Alexandrescu:
> > On 2/17/14, 10:59 AM, Jesse Phillips wrote:
> >> On Monday, 17 February 2014 at 17:03:46 UTC, Andrei Alexandrescu wrote:
> >>> On 2/16/14, 12:09 PM, Russel Winder wrote:
> >>>> Someone with serious knowledge should wade into this campaign of FUD.
> >>>> The whole thread is wrong-headed.
> >>>
> >>> Thanks for mentioning this. It's an interesting thread. I posted a
> >>> response:
> >>> https://groups.google.com/forum/#!msg/golang-nuts/rxOz-QMyHr4/BbNR_H1zyKkJ
> >>>
> >>>
> >>>
> >>> Andrei
> >>
> >> It looks like you've been completely ignored.
> >
> > This may be partly a logistics issue - my name appears garbled.
> >
> >> And I love how the Sort package is their great example of implementing a
> >> generic algorithm. I consider it a package which demonstrates the
> >> problem with lack of generics.

It is hard to disagree, and I really like Go for its goroutines and
channels.

> > I would agree that Go's sort tends to confuse people about what problems
> > can and cannot be solved with Go-style interfaces.
> >
> >
> > Andrei
> >
> 
> You have provided a very nice answer.
> 
> The problem with Go generics is religious, I might have to eat my own 
> words, but I seriously doubt they will ever support it.

There does appear to be a level of intransigence about the expression of
the opinion, and indeed the whole dichotomy. I admire the attempt to
provide strongly typed duck typing, and the challenge to the need for
generics as an orthodoxy. However there is a time to declare a position
not entirely viable and to look for a solution. My feeling is the Go
core team should move from "we haven't seen a generics system we like"
to "we are actively investigating a generics system for Go". Sadly this
can only be for Go 2 since they have declared an absolute backward
compatibility position for Go 1.

> They are too focused with Java and C++ as models, to accept anything 
> else as proof of them being wrong.

Not to mention C#. And OCaml and Haskell.

Sadly I don't have the time in the near future to try and design and
implement a CSP (process and channels) system for D. Currently JCSP, C
++CSP2, PyCSP, Python-CSP are the realizations of CSP I know of, and all
of them were a lot of work.

Go has effectively proved that CSP (or at least it's equivalence of it:
Rob Pike maintains he developed hos ideas independently in the
Newsqueak, Alef, Limbo sequence) is an extremely sensible architecture
for high performance concurrency and parallelism in a commercial
context. Analogously DataRush has shown the effectiveness of a more
general dataflow model in Big Data.

What we really need is a couple of PhD students to work on this.

-- 
Russel.
=============================================================================
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder at ekiga.net
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel at winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder



More information about the Digitalmars-d mailing list