std.allocator needs your help

Jacob Carlborg doob at me.com
Mon Sep 23 11:52:51 PDT 2013


On 2013-09-23 17:47, Manu wrote:

> I like operator new. It goes blue, and the statement isn't riddled with
> exclamation marks.

For Ruby, many editors and IDE's highlight standard built in functions 
as keywords. Like "new", "require", "attr_accessor" (and friends) to 
mention a few.

> Imagine if new was a template (it would have to be a template).
> Allocating a template would require nested template syntax every time,
> which is pretty ugly.
>
>    X x = new!(X!arg(args...)); // ewoo, paren spam...

Why not:

X x = new!X(args);

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list