www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Article on programming language adoption (x-post from /r/programming)

reply "John Colvin" <john.loughran.colvin gmail.com> writes:
http://www.eecs.berkeley.edu/~lmeyerov/projects/socioplt/papers/adoptquant.pdf
Aug 01 2013
parent reply "Dicebot" <public dicebot.lv> writes:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
Aug 01 2013
next sibling parent "bearophile" <bearophileHUGS lycos.com> writes:
Dicebot:

 Stop the world, I want to get out!
The article linked by John Colvin is not much interesting. Regarding that comment about unit testing and types there could be several explanations, like: - For their kind of coding static typing is not that needed/good. - They only have experience with languages with inflexible static typing. - Dynamic typing plus many unittests is "good enough" for certain coding purposes. Eventually I think the most used languages will grow a flexible type system, gradual typing, and we'll see the dynamic and static typing mix so much that the discussion will become mostly TypeScript, and so on. Bye. bearophile
Aug 01 2013
prev sibling next sibling parent reply "Chris" <wendlec tcd.ie> writes:
On Thursday, 1 August 2013 at 13:21:23 UTC, Dicebot wrote:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
"We found that developers gener- ally value expressiveness and speed of development over language-enforced correctness." I'll never understand why typing is regarded as such a big effort that slows down development. The terrible yoke of typing!
Aug 01 2013
next sibling parent "Meta" <jared771 gmail.com> writes:
On Thursday, 1 August 2013 at 13:40:31 UTC, Chris wrote:
 "We found that developers gener-
 ally value expressiveness and speed of development over
 language-enforced correctness."

 I'll never understand why typing is regarded as such a big 
 effort that slows down development. The terrible yoke of typing!
Sounds to me like their study was limited to Silicon Valley web startups. I bet if the sample size was more diverse they'd get different results.
Aug 01 2013
prev sibling parent reply "Tofu Ninja" <emmons0 purdue.edu> writes:
On Thursday, 1 August 2013 at 13:40:31 UTC, Chris wrote:
 On Thursday, 1 August 2013 at 13:21:23 UTC, Dicebot wrote:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
"We found that developers gener- ally value expressiveness and speed of development over language-enforced correctness." I'll never understand why typing is regarded as such a big effort that slows down development. The terrible yoke of typing!
I don't think its that people think typing is bad, I think its that people don't like unnecessary typing, as typing is the main interface between us and our program its obvious that we would want that interface to be as efficient as possible. Personally that is why I came to D, because it was easier to be more concise in it than in C++, not because of the amazing template system or the fast compile time or the safety, I found out about them after the fact. I came simply because I thought that C++'s syntax was bloated and ugly and that D's syntax was a bit cleaner and slimmed down. Simple example, why would I want to type "node->next" when I could just type "node.next". On the surface its only one more character but in reality its the difference between pressing one key that you are used to pressing in every day typing(the period) or the combination of pressing a '-' then holding down the shift and pressing the '.' key, its made worse by the fact that the '-' and the '.' are so far away from each other. When every you are trying to optimize for speed you need to always be aware of your bottle necks, for streaming video its internet speed, for a CUDA application its main memory, for coding its they keyboard.
Aug 01 2013
next sibling parent reply "Chris" <wendlec tcd.ie> writes:
On Thursday, 1 August 2013 at 15:01:39 UTC, Tofu Ninja wrote:
 On Thursday, 1 August 2013 at 13:40:31 UTC, Chris wrote:
 On Thursday, 1 August 2013 at 13:21:23 UTC, Dicebot wrote:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
"We found that developers gener- ally value expressiveness and speed of development over language-enforced correctness." I'll never understand why typing is regarded as such a big effort that slows down development. The terrible yoke of typing!
I don't think its that people think typing is bad, I think its that people don't like unnecessary typing, as typing is the main interface between us and our program its obvious that we would want that interface to be as efficient as possible. Personally that is why I came to D, because it was easier to be more concise in it than in C++, not because of the amazing template system or the fast compile time or the safety, I found out about them after the fact. I came simply because I thought that C++'s syntax was bloated and ugly and that D's syntax was a bit cleaner and slimmed down. Simple example, why would I want to type "node->next" when I could just type "node.next". On the surface its only one more character but in reality its the difference between pressing one key that you are used to pressing in every day typing(the period) or the combination of pressing a '-' then holding down the shift and pressing the '.' key, its made worse by the fact that the '-' and the '.' are so far away from each other. When every you are trying to optimize for speed you need to always be aware of your bottle necks, for streaming video its internet speed, for a CUDA application its main memory, for coding its they keyboard.
I think they meant typing as in "strong/weak typing" string text; text = "Hello!"; as opposed to text = "Hello" var text = "Hello" Dynamic typing, although it saves a few keystrokes, can introduce some subtle bugs. I think D's auto keyword for obvious cases is pretty good.
Aug 01 2013
parent "Tofu Ninja" <emmons0 purdue.edu> writes:
On Thursday, 1 August 2013 at 15:12:19 UTC, Chris wrote:
 On Thursday, 1 August 2013 at 15:01:39 UTC, Tofu Ninja wrote:
 On Thursday, 1 August 2013 at 13:40:31 UTC, Chris wrote:
 On Thursday, 1 August 2013 at 13:21:23 UTC, Dicebot wrote:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
"We found that developers gener- ally value expressiveness and speed of development over language-enforced correctness." I'll never understand why typing is regarded as such a big effort that slows down development. The terrible yoke of typing!
I don't think its that people think typing is bad, I think its that people don't like unnecessary typing, as typing is the main interface between us and our program its obvious that we would want that interface to be as efficient as possible. Personally that is why I came to D, because it was easier to be more concise in it than in C++, not because of the amazing template system or the fast compile time or the safety, I found out about them after the fact. I came simply because I thought that C++'s syntax was bloated and ugly and that D's syntax was a bit cleaner and slimmed down. Simple example, why would I want to type "node->next" when I could just type "node.next". On the surface its only one more character but in reality its the difference between pressing one key that you are used to pressing in every day typing(the period) or the combination of pressing a '-' then holding down the shift and pressing the '.' key, its made worse by the fact that the '-' and the '.' are so far away from each other. When every you are trying to optimize for speed you need to always be aware of your bottle necks, for streaming video its internet speed, for a CUDA application its main memory, for coding its they keyboard.
I think they meant typing as in "strong/weak typing" string text; text = "Hello!"; as opposed to text = "Hello" var text = "Hello" Dynamic typing, although it saves a few keystrokes, can introduce some subtle bugs. I think D's auto keyword for obvious cases is pretty good.
Now that you said that, you comment makes more sense to me(I was wondering why you liked to type so much :/)... I agree with you that I don't really see why people make a big deal about it, but it can be annoying and repetitive to do something like... someClassNameThatIsReallyLong x = new someClassNameThatIsReallyLong(); But as you said, auto is a good solution to that... I think it still comes back to my main point from before, the redundancy is not necessary. Unnecessary typing = bad in most peoples minds.
Aug 01 2013
prev sibling next sibling parent reply "Dicebot" <public dicebot.lv> writes:
On Thursday, 1 August 2013 at 15:01:39 UTC, Tofu Ninja wrote:
 When every you are trying to optimize for speed you need to 
 always be aware of your bottle necks, for streaming video its 
 internet speed, for a CUDA application its main memory, for 
 coding its they keyboard.
I don't buy it. In a daily programming actually writing code takes no more than 10% of time for me. 30% planning what needs to be done, 30% figuring out what some piece of code does, 30% debugging. Even full elimination of typing phase (literally, imagine some magic tool that directly translate your thoughts to code) wont be as useful as something that halves time for _any_ of three other parts. And static strong typing helps them all. As well as any compile-verifiable correctness. People that have bottlenecks in actually writing code must be genius and never make mistakes.
Aug 01 2013
parent "Tofu Ninja" <emmons0 purdue.edu> writes:
On Thursday, 1 August 2013 at 15:39:25 UTC, Dicebot wrote:
 On Thursday, 1 August 2013 at 15:01:39 UTC, Tofu Ninja wrote:
 When every you are trying to optimize for speed you need to 
 always be aware of your bottle necks, for streaming video its 
 internet speed, for a CUDA application its main memory, for 
 coding its they keyboard.
I don't buy it. In a daily programming actually writing code takes no more than 10% of time for me. 30% planning what needs to be done, 30% figuring out what some piece of code does, 30% debugging. Even full elimination of typing phase (literally, imagine some magic tool that directly translate your thoughts to code) wont be as useful as something that halves time for _any_ of three other parts. And static strong typing helps them all. As well as any compile-verifiable correctness. People that have bottlenecks in actually writing code must be genius and never make mistakes.
That is why I chose to say that it was a bottleneck in coding, not in development. The amount of text required to code something has effects on the things you mentioned, for instance having a more verbose language can help prevent errors by making the writer think about every thing he is writing, but can also cause more errors as more code means more places for miss types. Text amount can also effect code comprehension. For instance, having a very wordy language can sometimes be hard to understand as it is simply more for your brain to process. On the other hand a very compact language can be hard to understand as their might be to many assumptions and implicit information that the reader my not have. Debugging kind of falls in this as well as it requires you to fully comprehend what is going on to be able to find the bug. As for planing, I generally feel that this is much more language agnostic(or maybe I should say syntax agnostic?) The only times the specific language helps me plan is if their is some really nifty feature that makes what I am trying to do much more simple(like mixins or the simplicity of templates in D).
Aug 01 2013
prev sibling next sibling parent =?UTF-8?B?QWxpIMOHZWhyZWxp?= <acehreli yahoo.com> writes:
On 08/01/2013 08:01 AM, Tofu Ninja wrote:

 Simple example, why would I want to type "node->next" when I could just
 type "node.next".
However, that distinction allows accessing members of the pointer versus the members of the pointee. (Imagine 'node' is a type that overloads operator-> like smart pointers do.) On the other hand, D's reference semantics make the distinction disappear for classes. But then there is the inconvenience of not being able to access the class variable versus the class object at least for some operations: auto o = new MyClass(); While almost everything else that is accessed by the dot operator is applied to the object, o.sizeof is applied to the variable. One thing to keep in mind... Ali
Aug 01 2013
prev sibling parent Walter Bright <newshound2 digitalmars.com> writes:
On 8/1/2013 8:01 AM, Tofu Ninja wrote:
 Simple example, why would I want to type "node->next" when I could just type
 "node.next".
The real problem with node->next as opposed to node.next is if node changes from being a reference type to being a value type - then you've got to edit every dang use of it. C++ also uses :: instead of .
Aug 01 2013
prev sibling parent Gambler <fake feather.org.ru> writes:
On 8/1/2013 9:21 AM, Dicebot wrote:
 They see more value in unit
tests than types, both overall and as a debugging aid. Fur- thermore, how features are presented strongly influences developer feelings about them, such as prioritizing class in- terfaces much higher than static types Stop the world, I want to get out!
This does not surprise me. TDD has been sold as One True Way of programming for decades now. A lot of modern developers just throw the code (and tests, which are also code) at the problem until it seems solved. Using type system or declarative functional programming to eliminate certain errors is often not considered during development.
Aug 05 2013