Thread overview
Re: Migrating to Shared
May 14, 2009
bobef
May 14, 2009
BCS
May 14, 2009
Leandro Lucarella
May 14, 2009
dsimcha
May 14, 2009
BCS
May 14, 2009
dsimcha
May 15, 2009
Rainer Deyke
May 14, 2009
Walter Bright
May 15, 2009
Don
May 14, 2009
Walter Bright Wrote:

> I wrote a brief article which should help:
> 
> http://www.digitalmars.com/d/2.0/migrate-to-shared.html


__gshared, __etc. These look ugly IMHO. :)
May 14, 2009
Hello bobef,

> Walter Bright Wrote:
> 
>> I wrote a brief article which should help:
>> 
>> http://www.digitalmars.com/d/2.0/migrate-to-shared.html
>> 
> __gshared, __etc. These look ugly IMHO. :)
> 

I think that's the point: they look ugly because they are ugly.


May 14, 2009
bobef wrote:
> __gshared, __etc. These look ugly IMHO. :)

They're only allowed in safe mode, and are meant to inspire people to use them only when there's no other choice. Hence the unattractiveness <g>
May 14, 2009
BCS, el 14 de mayo a las 16:48 me escribiste:
> Hello bobef,
> 
> >Walter Bright Wrote:
> >>I wrote a brief article which should help: http://www.digitalmars.com/d/2.0/migrate-to-shared.html
> >__gshared, __etc. These look ugly IMHO. :)
> 
> I think that's the point: they look ugly because they are ugly.

I prefer normal keywords for standard things (keywords or symbols starting with __ are historically reserved for compiler specific features or even private stuff in Python). For __gshared I agree that it's something ugly and it's fine if it looks ugly.

But __traits?! Come on! __traits is beutiful, it deserves a beutiful keyword ;)

-- 
Leandro Lucarella (luca) | Blog colectivo: http://www.mazziblog.com.ar/blog/
----------------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------------
May 14, 2009
== Quote from Leandro Lucarella (llucax@gmail.com)'s article
> BCS, el 14 de mayo a las 16:48 me escribiste:
> > Hello bobef,
> >
> > >Walter Bright Wrote:
> > >>I wrote a brief article which should help: http://www.digitalmars.com/d/2.0/migrate-to-shared.html
> > >__gshared, __etc. These look ugly IMHO. :)
> >
> > I think that's the point: they look ugly because they are ugly.
> I prefer normal keywords for standard things (keywords or symbols starting
> with __ are historically reserved for compiler specific features or even
> private stuff in Python). For __gshared I agree that it's something ugly
> and it's fine if it looks ugly.
> But __traits?! Come on! __traits is beutiful, it deserves a beutiful
> keyword ;)

True.  I think I subconsciously avoid anything with an __ in front of it because
to me the connotation of an __ is "Only works if the stars align just right.
We're trying to scare you away from this feature for a reason.  Here be monsters."
 If traits, excuse me, __traits, is stable enough not to deserve this connotation,
then it absolutely deserves its own keyword.
May 14, 2009
Reply to dsimcha,

> True.  I think I subconsciously avoid anything with an __ in front of
> it because to me the connotation of an __ is "Only works if the stars
> align just right. We're trying to scare you away from this feature for a reason.  Here be monsters."

like __gshared? <g>

> If traits, excuse me, __traits, is stable enough not to deserve this
> connotation, then it absolutely deserves its own keyword.

I think traits should get first class treatment as it really isn't being used as the backdoor hack that the __ implies.


May 14, 2009
== Quote from BCS (ao@pathlink.com)'s article
> Reply to dsimcha,
> > True.  I think I subconsciously avoid anything with an __ in front of it because to me the connotation of an __ is "Only works if the stars align just right. We're trying to scare you away from this feature for a reason.  Here be monsters."
> like __gshared? <g>

Exactly, except __gshared deserves this treatment.
May 15, 2009
Leandro Lucarella wrote:
> I prefer normal keywords for standard things (keywords or symbols starting with __ are historically reserved for compiler specific features or even private stuff in Python). For __gshared I agree that it's something ugly and it's fine if it looks ugly.
> 
> But __traits?! Come on! __traits is beutiful, it deserves a beutiful keyword ;)

I like the idea of using __ for temporary, transitional, and
experimental keywords.  Using __ has several advantages here:
  - It's unlikely to collide with existing identifiers.
  - You can create as many of them as you want without worrying about
namespace pollution.
  - It's ugly as a reminder that the feature is temporary, transitional,
or experimental.
  - It's easy to search for and easy to globally replace with a real
keyword.

Eventually all features using __ keywords should be removed, renamed, or modified in such as way that they do not require a keyword at all.


-- 
Rainer Deyke - rainerd@eldwood.com
May 15, 2009
Walter Bright wrote:
> bobef wrote:
>> __gshared, __etc. These look ugly IMHO. :)
> 
> They're only allowed in safe mode, and are meant to inspire people to use them only when there's no other choice. Hence the unattractiveness <g>

Agreed. Yet as others have said, __traits deserves a beautiful keyword.