Safer casts

Dee Girl deegirl at noreply.com
Mon May 12 15:15:04 PDT 2008


Yigal Chripun Wrote:

> > The benefit is choice.
> 
> choice of what? You've said so yourself, both templated and
> non-templated versions of the sort-with-delegate are identical.

Yigal-san this is incorrect again. I am sorry!! Did you do the disassembly I sent you? It is very simple to change to use alias (not string). You can see how sort makes direct call to the alias, not indirect! It is always good to test first and write after.

> you want those string templates (which i don't like) than fine, define
> them as templates and i won't use them. but the version with the
> delegate is needlessly a template.
> 
> I guess I wouldn't object as much if D's syntax for calling templated
> code weren't different from regular functions which would bring a more
> uniform syntax (take a look at macros in Nemerle).
> Does it irritate only me? maybe I am the odd one here. I just don't want
> to care if one array function is a generic template, while another
> isn't. ideally (not possible in current D) both forms should have the
> same syntax, so the end user (me) doesn't need to know nor care about
> what sort of implementation was chosen.

There are many things you write and then write is your opinion and others can disagree. It is good when opinion is about subjective things. And opinions are equal on subjective things like the syntax you write about. But some times you write just wrong things and do not want to try and see what is true. It does not work to say it is an opinion and others can disagree. Wrong is not an opinion. Wrong and right are not equal. It is good to try find the truth, not write wrong things as opinions. If you want truth take the disassembly and see. Thank you, Dee Girl



More information about the Digitalmars-d mailing list