Fed-up with strongly typing
-
Mix the two... go for C#
In real-life I am pro consensus but in software programming I like to avoid non-firm-decisions as much as I can. For me it is one XOr the other...
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
Strong typing is a good thing. A mistake you make with types in a weakly typed language will result in something unexpected happening at runtime, and having the compiler catch your mistakes is a big bonus. However, programming languages are often rather cumbersome at defining the types, requiring you to do so when it's clear from the context. E.g. I have some Java code on my screen containing
for(Model model : models){
List<String> customProperties = model.getCustomProperties();
// ... do stuff
}Neither of those two type declarations is necessary because they are inferrable from the context (i.e. the return type of getCustomProperties and the iterator type of models), and making you type them is an increase in typing for little benefit. C# has gone down the road of removing this with var and with lambda functions (which infer their argument and result types from their context).
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
Strongly typed lets the compiler catch mistakes. Are you saying a "proficient" programmer never makes mistakes and so doesn't benefit from a strongly typed language? I don't think that's the case.
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
I'm still reserving judgement. As you say, often it takes more typing. I'm also not entirely convinced by the "prevents bugs"-argument - strong typing isn't really strong enough for that, you'd need something based on abstract interpretation to catch actual bugs (ok so strong typing prevents me from, say, using an int as if it was an array, but it's not like I ever do that anyway). It catches a typo now and then.. but not all That often, so it's still a trade-off, not a clear-cut win for either side. Most things that are actually wrong are logic errors etc. Strong typing is of little to no help there. However, despite recent advances, I'm not convinced that dynamic languages can ever be fast. The source doesn't give them enough easily-extractable information. In fact, neither do strongly typed languages, but it's still more. What should it look like then? I'm not certain yet. I'm exploring (ie making compilers for new languages and seeing how well they work) in the direction of making as much as possible a compile-time error. Things like dereferencing null and accessing an array outside of its bounds. Either abstract interpretation finds that due to the flow of your program it cannot possibly happen, or you have to explicitly write, for example, "assume x != null" or put a "where x != null" as precondition on the method declaration. By dereferencing x you were always making that assumption, but now it's explicit and obvious. The interprocedural analysis required to prevent a metric ton of false-positives is making it a little hard. Just an experiment of course, failure is always an option :)
-
Strongly typed lets the compiler catch mistakes. Are you saying a "proficient" programmer never makes mistakes and so doesn't benefit from a strongly typed language? I don't think that's the case.
that is definitely not the case. but a proficient programmer is anyway testing is code and just don't rely on compilation, right?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
Complaining about having to write a little more code to be genuinely strongly typed is not a valid reason for using dynamic over strong typing. Look at how equality operators in PHP work, or don't work if we're being totally honest.. I'd rather incur a little more overhead in having to properly declare everything than spend the same time sifting through code written in what is essentially still a procedural language, desperately trying to find out why my
if(a == b)
isn't working like it should. -
-
Complaining about having to write a little more code to be genuinely strongly typed is not a valid reason for using dynamic over strong typing. Look at how equality operators in PHP work, or don't work if we're being totally honest.. I'd rather incur a little more overhead in having to properly declare everything than spend the same time sifting through code written in what is essentially still a procedural language, desperately trying to find out why my
if(a == b)
isn't working like it should.(a==b) is nothing I would personally write in a dynamic language...
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
I prefer strong typing. I'm happy for those who don't to do their thing without it in JavaScript or WhateverLang(TM) at a minimum safe distance of two parsecs from me. When they do however and then have no idea why their function produces the correct result only on even numbered days of the week don't expect me to come to the rescue, I'm out of distress call range. Yes they will be 'code complete' before I will and yes they will almost certainly write more lines of code per day. However when I have debugged through the use cases for my code I will KNOW that it works and will remain working barring an act of God or at least RMS. The same cannot be said for the script kiddies with their fingers crossed sweating the Q.A. results. ;)
"The secret of happiness is freedom, and the secret of freedom, courage." Thucydides (B.C. 460-400)
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
There is a difference between strong-typing and static typing and I am in favor of both by a wide-margin. Although, I am quite the Javascript Kiddie.
Need custom software developed? I do custom programming based primarily on MS tools with an emphasis on C# development and consulting. "And they, since they Were not the one dead, turned to their affairs" -- Robert Frost "All users always want Excel" --Ennis Lynch
-
that is definitely not the case. but a proficient programmer is anyway testing is code and just don't rely on compilation, right?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
In real-life I am pro consensus but in software programming I like to avoid non-firm-decisions as much as I can. For me it is one XOr the other...
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Strongly typing has one big advantage: it will force you to grow from a jerk to a proficient programmer. Yes, many programmers never get proficient but then strongly typing is not the cause :-) But here we are: when you are proficient in your domain of expertise (eg: embedded, gaming, LOB apps, multi-million users websites or whatever is your mod) then strongly typing is just a pain... It only multiplies by X (I am curious here... anyone? ) the number of reserved keywords you have to type to get to an equivalent result that you would get with a dynamic language. What do you guys think?
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
Guirec Le Bars wrote:
you have to type
I often hear complaints about how much typing someone has to do. If you don't like typing, you shouldn't be a programmer. As to dynamic typing, while it's cool and fun, in the long run, the number of problems that I've had to fix that simply wouldn't be there in a strongly typed language all but eliminates for me the benefits. Not to mention that I wouldn't write anything that requires performance in a dynamic language, as these usually cannot be compiled into native assembly code but are either interpreted or are run in a VM. So I'll say it again, but this time metaphorically: If you don't like typing, you shouldn't be a programmer. Marc
Testers Wanted!
Latest Article: User Authentication on Ruby on Rails - the definitive how to
My Blog -
And what if the proficient programmer misses one of the code paths during his tests? The compiler will surely check them all.
Freak30 wrote:
The compiler will surely check them all.
I want one of these! Please let me know which compiler as you are using. A compiler which checks all code path is priceless!
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
I prefer strong typing. I'm happy for those who don't to do their thing without it in JavaScript or WhateverLang(TM) at a minimum safe distance of two parsecs from me. When they do however and then have no idea why their function produces the correct result only on even numbered days of the week don't expect me to come to the rescue, I'm out of distress call range. Yes they will be 'code complete' before I will and yes they will almost certainly write more lines of code per day. However when I have debugged through the use cases for my code I will KNOW that it works and will remain working barring an act of God or at least RMS. The same cannot be said for the script kiddies with their fingers crossed sweating the Q.A. results. ;)
"The secret of happiness is freedom, and the secret of freedom, courage." Thucydides (B.C. 460-400)
Matthew Faithfull wrote:
the script kiddies
I am not sure you get me right... I am talking about experienced programmers not kiddies.
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
Matthew Faithfull wrote:
the script kiddies
I am not sure you get me right... I am talking about experienced programmers not kiddies.
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
My point is that experienced programmers don't use 'dynamically' typed languages unless they have to because experience teaches them that it's a bad idea. It doesn't seem like a bad idea at first because it's 'easy' but when you look back at the amount of time spent debugging and the stability/lifetime/readability of the code never mind the quality of the tools available to debug it JavaScript, Python, PHP and all their unholy offspring should have been drowned at birth.
"The secret of happiness is freedom, and the secret of freedom, courage." Thucydides (B.C. 460-400)
-
Guirec Le Bars wrote:
you have to type
I often hear complaints about how much typing someone has to do. If you don't like typing, you shouldn't be a programmer. As to dynamic typing, while it's cool and fun, in the long run, the number of problems that I've had to fix that simply wouldn't be there in a strongly typed language all but eliminates for me the benefits. Not to mention that I wouldn't write anything that requires performance in a dynamic language, as these usually cannot be compiled into native assembly code but are either interpreted or are run in a VM. So I'll say it again, but this time metaphorically: If you don't like typing, you shouldn't be a programmer. Marc
Testers Wanted!
Latest Article: User Authentication on Ruby on Rails - the definitive how to
My BlogMarc Clifton wrote:
If you don't like typing, you shouldn't be a programmer.
I am a programmer cause I never liked repetitive tasks, I believe that typing .net/java code is highly repetitive... You might think differently: fair enough. But with all respect I am not judging what you should or should not be or do.
Marc Clifton wrote:
Not to mention that I wouldn't write anything that requires performance in a dynamic language
Many dynamic languages outperform statically typed languages... just have a go with LUA you should not be disappointed. And code is not all... the environment has a lot to do: run some compiled C# in IIS and compare performance with interpreted JS in node or run PHP within ligthy and you might end-up handling more than 3000 requests/sec http://redmine.lighttpd.net/projects/lighttpd/wiki/PoweredByLighttpd[^]... Drop me a note when you achieve the same with csharp :-D
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
-
-
Marc Clifton wrote:
If you don't like typing, you shouldn't be a programmer.
I am a programmer cause I never liked repetitive tasks, I believe that typing .net/java code is highly repetitive... You might think differently: fair enough. But with all respect I am not judging what you should or should not be or do.
Marc Clifton wrote:
Not to mention that I wouldn't write anything that requires performance in a dynamic language
Many dynamic languages outperform statically typed languages... just have a go with LUA you should not be disappointed. And code is not all... the environment has a lot to do: run some compiled C# in IIS and compare performance with interpreted JS in node or run PHP within ligthy and you might end-up handling more than 3000 requests/sec http://redmine.lighttpd.net/projects/lighttpd/wiki/PoweredByLighttpd[^]... Drop me a note when you achieve the same with csharp :-D
Seulement, dans certains cas, n'est-ce pas, on n'entend guère que ce qu'on désire entendre et ce qui vous arrange le mieux... [^] Joe never complained of anything but ever did his duty in his way of life, with a strong hand, a quiet tongue, and a gentle heart [^]
Guirec Le Bars wrote:
I believe that typing .net/java code is highly repetitive.
Well, typing itself is repetitive - 30 or so keys, over and over and over again! ;)
Guirec Le Bars wrote:
just have a go with LUA you should not be disappointed.
Interesting. If I can wrap my head around learning yet another language. I have a some very complex analysis algorithms that I think would make a great test case for measuring the performance of any language / environment. ;)
Guirec Le Bars wrote:
Drop me a note when you achieve the same with csharp
Well, is that IIS or C#? (I am rather biased against IIS, I find it's configuration alone to be a total PITA.) Compare that to my only other experience, Rails - you just fire it up. It's so freakin' simple! Marc
Testers Wanted!
Latest Article: User Authentication on Ruby on Rails - the definitive how to
My Blog