August 20, 2013
First, thanks all for returning (or keeping up) a constructive discussion.

@monarch_dodra

My error, sorry. I was talking in the context of a western view, ignoring China, Japan, Koreas (and probably some more Asian countries/languages, too). Not meaning to propagate that as generally sound practice, I personally happen to work in a very western-centric world where, say, Russian (kyrillic alphabet) is already considered *very* exotic. In that context, however, 16bits are plenty enough.


@H. S. Teoh

I remember myself to stubbornly refuse Windows and staying with Dos or Unix (cli). Well, work forced me to make compromises and since FreeBSD came up (and Solaris worked on X86) I made one step and another ... and are (by your standards) pretty rotten nowadays *g

I got your point and I agree. Yes, it's a major plus for D to be cli useable and not requiring a (probably bloated) IDE. OTOH, I'm quite liberal in that and never had qualms about using an IDE (or, in old days, E, brief and the like); after all, a computers raison d'etre is to make our lifes easier and to take on a gazillion of boring little tasks, no?
But it's, of course, strongly desirable to have "direct access" on the commandline, which IMO is valid for other areas, too. Actually it always was oe of my reasons to outright hate Windows for keeping me away from its guts.


@Timon Gehr

> Here I'd tend to disagree. Code duplication is the compiler's job.
I get your point but I disagree. Sure, looking at it from D's point of view (with very powerful and elaborate "duplication" facilities) you are right. I see that, however, as a (valuable) add-on. It doesn't change the fact that the technical part of code production is an editors job; just think code completion, intellisense and the like.
Maybe it's just a perspective thing. I tend to feel that the editor is the interface between the system and myself. What is produced with it will then be the input to a compiler.
Anyway, that's not important because thanks to D's facilities we can actually have it both ways ;)

As for generics: Maybe I'm not the brightest guy around but I have suceeded in noticing that there seems to be tendency in D's community to not react warmly to critical remarks regarding generics ...
Actually, I'm far away from hitting on D. Even if, suppose, its generics were lousy, there would still be lots of solid good reasons to like D and to consider it one of the best approaches wide and far. It might as well be my fault to be stubbornly fixed on "generics done right".
August 20, 2013
On 8/20/13 10:47 AM, Walter Bright wrote:
> On 8/20/2013 7:21 AM, Joseph Rushton Wakeling wrote:
>> On 20/08/13 00:00, Walter Bright wrote:
>>> While not unique to D, I believe that ranges will become a killer
>>> feature -
>>> killer enough that languages that don't support pipeline programming
>>> will start
>>> looking like propeller driven airliners.
>>
>> On that note -- I was chatting with a (very functional- and
>> Lisp-oriented)
>> friend about D and, when ranges were mentioned, he immediately
>> connected it with
>> Clojure's concept of "sequences": http://clojure.org/sequences
>>
>> Does anyone know the history/relationship here between these and D's
>> ranges? Was
>> it a direct influence from D, or convergent evolution -- and can
>> anyone comment
>> on the relative merits of the D vs. Clojure approaches?
>
> This style of programming has been around at least since the Unix "pipes
> and filters" model. It also appears as C#'s LINQ programming style.
>
> However, LINQ and Clojure were not direct influences on D's ranges.

It's a common omission to equate D's ranges with pipes/filters. That misses the range categorization, which is inspired from C++ iterators.

A relatively accurate characterization of D ranges is a unification of C++ iterators with pipes/filters.


Andrei

August 20, 2013
On 8/20/13 11:32 AM, Walter Bright wrote:
> On 8/20/2013 11:17 AM, Joseph Rushton Wakeling wrote:
>> On 20/08/13 19:47, Walter Bright wrote:
>>> This style of programming has been around at least since the Unix
>>> "pipes and
>>> filters" model. It also appears as C#'s LINQ programming style.
>>>
>>> However, LINQ and Clojure were not direct influences on D's ranges.
>>
>> Since Clojure is more recent than D, and AFAICT its sequences API
>> seems to have
>> arrived in later versions of the language, I wondered if the influence
>> had been
>> in the opposite direction.
>>
>> When were ranges first introduced in D?
>>
>
> Eh, I'd have to go back through the github history :-(
>
> The idea goes way back. Matthew Wilson and I were thinking about how to
> do C++ STL-like iterators, which were based on a pointer abstraction. I
> thought it was natural for D to do it as an array abstraction. There are
> some posts about it in the n.g. somewhere. The idea languished until
> Andrei joined us and figured out how it should work, and ranges were born.

http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com

Andrei

August 20, 2013
On 8/20/2013 1:49 PM, Andrei Alexandrescu wrote:
> On 8/20/13 11:32 AM, Walter Bright wrote:
>> The idea goes way back. Matthew Wilson and I were thinking about how to
>> do C++ STL-like iterators, which were based on a pointer abstraction. I
>> thought it was natural for D to do it as an array abstraction. There are
>> some posts about it in the n.g. somewhere. The idea languished until
>> Andrei joined us and figured out how it should work, and ranges were born.
>
> http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com

Awesome, thanks for digging that up!

August 20, 2013
On Tue, Aug 20, 2013 at 01:49:41PM -0700, Andrei Alexandrescu wrote:
> On 8/20/13 11:32 AM, Walter Bright wrote:
[...]
> >The idea goes way back. Matthew Wilson and I were thinking about how to do C++ STL-like iterators, which were based on a pointer abstraction. I thought it was natural for D to do it as an array abstraction. There are some posts about it in the n.g. somewhere. The idea languished until Andrei joined us and figured out how it should work, and ranges were born.
> 
> http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com
[...]

Wow. That must've been an awesome discussion. I can literally feel it oozing with excitement. :) We should put this link up on the wiki somewhere, maybe under "landmark historical documents" or something.


T

-- 
If a person can't communicate, the very least he could do is to shut up. -- Tom Lehrer, on people who bemoan their communication woes with their loved ones.
August 20, 2013
On 8/20/13 2:03 PM, H. S. Teoh wrote:
> On Tue, Aug 20, 2013 at 01:49:41PM -0700, Andrei Alexandrescu wrote:
>> On 8/20/13 11:32 AM, Walter Bright wrote:
> [...]
>>> The idea goes way back. Matthew Wilson and I were thinking about how
>>> to do C++ STL-like iterators, which were based on a pointer
>>> abstraction. I thought it was natural for D to do it as an array
>>> abstraction. There are some posts about it in the n.g. somewhere. The
>>> idea languished until Andrei joined us and figured out how it should
>>> work, and ranges were born.
>>
>> http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com
> [...]
>
> Wow. That must've been an awesome discussion. I can literally feel it
> oozing with excitement. :) We should put this link up on the wiki
> somewhere, maybe under "landmark historical documents" or something.

I was incredibly excited - so much, in fact, that I decided to share all that following a year-long absence.

Andrei

August 20, 2013
On 08/20/2013 01:43 PM, Andrei Alexandrescu wrote:

> the range categorization, which is inspired from C++ iterators.

All of that is explained in your "On Iteration" article:

  http://www.informit.com/articles/article.aspx?p=1407357

Ali

August 20, 2013
On 8/20/13, H. S. Teoh <hsteoh@quickfur.ath.cx> wrote:
>> http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com
> [...]
>
> Wow. That must've been an awesome discussion. I can literally feel it oozing with excitement. :) We should put this link up on the wiki somewhere, maybe under "landmark historical documents" or something.

There's also this:

http://forum.dlang.org/thread/gacvj5$28ec$1@digitalmars.com
August 20, 2013
On Tue, Aug 20, 2013 at 11:19:45PM +0200, Andrej Mitrovic wrote:
> On 8/20/13, H. S. Teoh <hsteoh@quickfur.ath.cx> wrote:
> >> http://forum.dlang.org/thread/ga46ok$2s77$1@digitalmars.com
> > [...]
> >
> > Wow. That must've been an awesome discussion. I can literally feel it oozing with excitement. :) We should put this link up on the wiki somewhere, maybe under "landmark historical documents" or something.
> 
> There's also this:
> 
> http://forum.dlang.org/thread/gacvj5$28ec$1@digitalmars.com

Sadly, the link to Andrei's presumably DDoc-generated page is no longer working.  :-(


T

-- 
Life would be easier if I had the source code. -- YHL
August 20, 2013
On 08/20/2013 10:24 PM, Ramon wrote:
>
> @Timon Gehr
>...
>
> As for generics: Maybe I'm not the brightest guy around but I have
> suceeded in noticing that there seems to be tendency in D's community to
> not react warmly to critical remarks regarding generics ...

Why would it be relevant for arguing a point whether reactions are warm or not?