www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Language feature suggestions: This and Super

reply "Tommi" <tommitissari hotmail.com> writes:
What do you think of adding to the language these couple of 
keywords just for syntactic sugar: This and Super. They'd be the 
types of this and super inside class and struct scope.

is(This == typeof(this))
...and...
is(Super == typeof(super))
Jun 15 2012
next sibling parent Gor Gyolchanyan <gor.f.gyolchanyan gmail.com> writes:
On Sat, Jun 16, 2012 at 9:18 AM, Tommi <tommitissari hotmail.com> wrote:
 What do you think of adding to the language these couple of keywords just
 for syntactic sugar: This and Super. They'd be the types of this and super
 inside class and struct scope.

 is(This == typeof(this))
 ...and...
 is(Super == typeof(super))
I think typeof(this) and typeof(super) is not too bad. -- Bye, Gor Gyolchanyan.
Jun 15 2012
prev sibling parent "Bernard Helyer" <b.helyer gmail.com> writes:
Not worth it, the typeof variants are fine.
Jun 15 2012