Hello,
First, what is the actual point of new? I find this keyword rather helpful in
that it reminds me the element is referenced/heap-allocated/GC'ed. But is there
any ambiguity on the language's side? We cannot construct a class instance in
any other way, AFAIK, and calling a class can
spir denis.s...@gmail.com wrote:
First, what is the actual point of new?
Mostly, it's a remnant from C++.
I find this keyword rather helpful in that it reminds me the element is
referenced/heap-allocated/GC'ed. But is there any ambiguity on the
language's side? We cannot construct a
On 11/11/10 20:02, spir wrote:
Hello,
First, what is the actual point of new? I find this keyword rather helpful in that it
reminds me the element is referenced/heap-allocated/GC'ed. But is there any ambiguity on the
language's side? We cannot construct a class instance in any other way,
spir schrieb:
Still, an other case when new annoys me is method chaining, because it makes
syntax heavier and less readable:
c = (new C(p)).do(x);
versus:
c = C(p).do(x);
Or, maybe, the parser could be clever enough to correctly decode:
c = new C(p).do(x);
Is this
On Thu, 11 Nov 2010 11:57:40 -0500, Daniel Gibson metalcae...@gmail.com
wrote:
spir schrieb:
Still, an other case when new annoys me is method chaining, because
it makes syntax heavier and less readable:
c = (new C(p)).do(x);
versus:
c = C(p).do(x);
Or, maybe, the parser
On Thu, 11 Nov 2010 12:10:42 -0500, Steven Schveighoffer
schvei...@yahoo.com wrote:
On Thu, 11 Nov 2010 11:57:40 -0500, Daniel Gibson
metalcae...@gmail.com wrote:
spir schrieb:
Still, an other case when new annoys me is method chaining, because
it makes syntax heavier and less readable:
Steven Schveighoffer schrieb:
On Thu, 11 Nov 2010 12:10:42 -0500, Steven Schveighoffer
schvei...@yahoo.com wrote:
On Thu, 11 Nov 2010 11:57:40 -0500, Daniel Gibson
metalcae...@gmail.com wrote:
spir schrieb:
Still, an other case when new annoys me is method chaining,
because it makes
On Thu, 11 Nov 2010 17:57:40 +0100
Daniel Gibson metalcae...@gmail.com wrote:
spir schrieb:
Still, an other case when new annoys me is method chaining, because it
makes syntax heavier and less readable:
c = (new C(p)).do(x);
versus:
c = C(p).do(x);
Or, maybe, the parser
On Thu, 11 Nov 2010 18:53:56 +0100
Daniel Gibson metalcae...@gmail.com wrote:
That being said, I'm really ambivalent on whether this needs to be
included. It's not that terrible that you have to parenthesize properly.
Also, I'm not sure if this is a common case.. although I had similar