Jump to page: 1 25  
Page
Thread overview
too much sugar not good for the health
Mar 21, 2007
Neal Becker
Mar 21, 2007
Johan Granberg
Mar 21, 2007
janderson
Mar 22, 2007
janderson
Mar 22, 2007
Walter Bright
Mar 23, 2007
Jeff Nowakowski
Mar 23, 2007
Stewart Gordon
Mar 23, 2007
Walter Bright
Mar 24, 2007
Ary Manzana
Mar 24, 2007
Walter Bright
Mar 24, 2007
torhu
Mar 24, 2007
Walter Bright
English vs. Esperanto (was: too much sugar not good for the health)
Mar 24, 2007
Stewart Gordon
Re: English vs. Esperanto
Apr 03, 2007
Kevin Bealer
Apr 03, 2007
Dan
Mar 24, 2007
Bruno Medeiros
Mar 24, 2007
Walter Bright
Mar 25, 2007
torhu
Mar 24, 2007
Bruno Medeiros
Mar 24, 2007
David B. Held
Mar 24, 2007
Ary Manzana
Mar 24, 2007
janderson
Mar 24, 2007
Charlie
Mar 24, 2007
Sean Kelly
Mar 24, 2007
janderson
Mar 21, 2007
Davidl
Mar 21, 2007
Stewart Gordon
Mar 21, 2007
Stewart Gordon
Mar 21, 2007
Sean Kelly
Mar 21, 2007
Derek Parnell
Mar 21, 2007
Stewart Gordon
Mar 21, 2007
Alexander Panek
Mar 21, 2007
David B. Held
Mar 21, 2007
Dan
Mar 22, 2007
David B. Held
Mar 21, 2007
Walter Bright
March 21, 2007
Reading through "D Specification", I'm a bit surprised.  I believe the goal of D is to be a clean, improved C++.  Yet, there are a number of instances where syntactic 'sugar' is added in ways that seem almost arbitrary.  The latest example I found is 'Functions as Array Properties'.  I'm not sure what overwhelming need this syntax fulfills, maybe I'm missing something.

There is a lot of extra conceptual overhead in adding extra syntax.  One might argue that "You don't have use it if you don't like it.".  That is, unfortunately, not really true.  If other's use it and I have to grok there code, I need to understand the extra rules.

I've been following D with great interest.  I hope the language will not add such 'features' without great need - it really detracts from the purity and simplicity.
March 21, 2007
Neal Becker wrote:

> Reading through "D Specification", I'm a bit surprised.  I believe the
> goal
> of D is to be a clean, improved C++.  Yet, there are a number of instances
> where syntactic 'sugar' is added in ways that seem almost arbitrary.  The
> latest example I found is 'Functions as Array Properties'.  I'm not sure
> what overwhelming need this syntax fulfills, maybe I'm missing something.
> 
> There is a lot of extra conceptual overhead in adding extra syntax.  One might argue that "You don't have use it if you don't like it.".  That is, unfortunately, not really true.  If other's use it and I have to grok there code, I need to understand the extra rules.
> 
> I've been following D with great interest.  I hope the language will not add such 'features' without great need - it really detracts from the purity and simplicity.

I agree that to much features is a bad idea. But I don't feel that the array property syntax is an unneeded feature, rather I fell that it should be generalized to cover all types and not just arrays. (It could be used to replace methods but I don't think that would be a good idea for D, at least not in the shot term)
March 21, 2007
"Neal Becker" <ndbecker2@gmail.com> wrote in message news:etr33u$46c$1@digitalmars.com...
>
> I've been following D with great interest.  I hope the language will not
> add
> such 'features' without great need - it really detracts from the purity
> and
> simplicity.

The only response I have to this is: have a look at Java to see a language with virtually no sugar.  It's so bland and unexpressive it _hurts_.  A tiny bit of sugar can go a long way to making the language more intuitive to use, not just prettier.


March 21, 2007
it's totally not arbitrary. since AA in D is a container, but we lack of
method to operate on it and even more with any resort to add method for it
on user land.
So functions as Array Properties in a language with AA is a must. it looks
beautiful, and we can extend our AA with funcs and they work as methods like
way. it's reasonable. i used to think in ur way either. But after u post
this, and i consider the AA's func stuff, i finally realize why we don't get
rid of this feature.

> Reading through "D Specification", I'm a bit surprised.  I believe the goal
> of D is to be a clean, improved C++.  Yet, there are a number of instances
> where syntactic 'sugar' is added in ways that seem almost arbitrary.  The
> latest example I found is 'Functions as Array Properties'.  I'm not sure
> what overwhelming need this syntax fulfills, maybe I'm missing something.
>
> There is a lot of extra conceptual overhead in adding extra syntax.  One
> might argue that "You don't have use it if you don't like it.".  That is,
> unfortunately, not really true.  If other's use it and I have to grok there
> code, I need to understand the extra rules.
>
> I've been following D with great interest.  I hope the language will not add
> such 'features' without great need - it really detracts from the purity and
> simplicity.

March 21, 2007
Neal Becker wrote:
> Reading through "D Specification", I'm a bit surprised.  I believe the goal
> of D is to be a clean, improved C++.  Yet, there are a number of instances
> where syntactic 'sugar' is added in ways that seem almost arbitrary.  The
> latest example I found is 'Functions as Array Properties'.  I'm not sure
> what overwhelming need this syntax fulfills, maybe I'm missing something.
> 
> There is a lot of extra conceptual overhead in adding extra syntax.  One
> might argue that "You don't have use it if you don't like it.".  That is,
> unfortunately, not really true.  If other's use it and I have to grok there
> code, I need to understand the extra rules.
> 
> I've been following D with great interest.  I hope the language will not add
> such 'features' without great need - it really detracts from the purity and
> simplicity.

You have a point, though the beauty & readability of D pretty much nullifies that. The syntax sugar that is added so far does not actually complicate the parsing so much, so D's syntax can still be seen as clean, IMHO.
March 21, 2007
Jarrett Billingsley wrote:
> "Neal Becker" <ndbecker2@gmail.com> wrote in message news:etr33u$46c$1@digitalmars.com...
>> I've been following D with great interest.  I hope the language will not add
>> such 'features' without great need - it really detracts from the purity and
>> simplicity.
> 
> The only response I have to this is: have a look at Java to see a language with virtually no sugar.  It's so bland and unexpressive it _hurts_.  A tiny bit of sugar can go a long way to making the language more intuitive to use, not just prettier. 
> 
> 

Agreed. Even Java are adding more an more sugar with each release. Also reading all that bland code takes more time to learn then simply learning a new feature.

Personally I don't think D is anywhere near the threshold of having to much.  Take a look at the most successful langugage (English), it keeps getting bigger and bigger every day.  We just don't have enough syntax to describe everything.  Really, for a beginner learning D its not that much more to learn.

Having said that, I'm still learning things about C++ (after 10years) and it is meant to  be one of the smaller languages (well not compared with java, but anyhow).  I think its more to do with the unexpected and sometimes weird behaviors of its syntax.  I have no problem figuring out what

I think D is more straight forward, things work as expected and will often encourage/replace well established design patterns.  D may have more terms however many replace what would otherwise be a more complicated in C++.  Which all adds up to  getting more done in less time.  It only takes a minute or 2 to learn a new concept.  If you use it more then twice, then you've probably got that time back.

-Joel
March 21, 2007
Alexander Panek wrote:
> [...]
> You have a point, though the beauty & readability of D pretty much nullifies that. The syntax sugar that is added so far does not actually complicate the parsing so much, so D's syntax can still be seen as clean, IMHO.

I think the ridiculous size of the front-end is a pretty good existence proof.  Take a look, Neal.

Dave
March 21, 2007
Davidl wrote:
> it's totally not arbitrary. since AA in D is a container, but we lack of
> method to operate on it and even more with any resort to add method for it
> on user land.
> So functions as Array Properties in a language with AA is a must. it looks
> beautiful, and we can extend our AA with funcs and they work as methods like
> way. it's reasonable. i used to think in ur way either. But after u post
> this, and i consider the AA's func stuff, i finally realize why we don't get
> rid of this feature.

We definitely should get rid of the shameful .sort and .reverse though.

Andrei
March 21, 2007
David B. Held wrote:
> Alexander Panek wrote:
>> [...]
>> You have a point, though the beauty & readability of D pretty much nullifies that. The syntax sugar that is added so far does not actually complicate the parsing so much, so D's syntax can still be seen as clean, IMHO.
> 
> I think the ridiculous size of the front-end is a pretty good existence proof.  Take a look, Neal.

Take a look at Polyglot. Even Java syntax is heinous to parse.

Andrei
March 21, 2007
Am Wed, 21 Mar 2007 08:16:08 -0700 schrieb janderson:

> Jarrett Billingsley wrote:
> Personally I don't think D is anywhere near the threshold of having to
> much.  Take a look at the most successful langugage (English), it keeps
> getting bigger and bigger every day.  We just don't have enough syntax
> to describe everything.

Without discussing what "successful" is supposed to mean in the realm of natural languages, I think the syntax of English is shrinking rather than growing. Plus, today's lingua franca is a tiny subset of English with a type discipline comparable to that of K&R C.

Apart from that, I agree with you that D's syntax is a lot easier to understand than that of C++.

Falk
« First   ‹ Prev
1 2 3 4 5