
Seven circles of hell for new elements of language
- Transfer

My last post about the new “dynamic” element caused a wave of reviews that are not usual for discussing new elements or language features. Many were excited and happy, but there were those who were upset that their language would “marry” with a new element.
C # had this situation for the var element in the past and is repeating now for dynamic. I don’t know, maybe there are seven circles of hell when their favorite programming language gets new opportunities. (Disclaimer: In fact, all this nonsense I am creating)
1. Shock and denial
With the addition of a new element, reactions of shock and denial are observed.
“Why did they add these lambdas? I just figured out the delegates! ”
“Delusional syntax. I will score on him "
“Generics will never steer! Remember my words
2. Shadows of Forgotten Ancestors
Even before the advent of new functionality, developers begin to nostalgic for the past, which never existed.
“I loved language X 10 years ago when it wasn’t so bloated.”
They forgot that in the past, it was necessary to introduce tight memory control and many other operations in which they were mired like in a quagmire.
3. Anger and fear, uncertainty and doubt
Later, nostalgia turn into anger and fear, uncertainty and doubt.
Look at the reaction of adding “goto” in PHP
"This is problem. Seriously, PHP has always been without goto, why turn the language into a public threat? ”
“Yes Robin, PHP is a threat terrorizing Gotham. Quickly Betmobile! ”
Dynamic got a similar share of anger:
“C # was a great static language. If I need a dynamic language, I will use something else! ”
Or
“I will never use this functionality”
Shortly before, anger turns into fear, uncertainty and doubt. var in C # is a direct proof of this. Many developers mistakenly wrote that the code will no longer be strictly typed, all this leads straight to hell.
“My friend used var in his program, which dawned on her and she independently formatted his hard drive, and also became the fault of the recent economic crisis. The cross on the belly "
They did not know, dynamic was already in development then, and he would really fulfill these promises;) The
new functionality will destroy all life on the planet.
4. Depression, Thoughts and Fortune Telling
"Sigh. I know that I have to learn a new feature, but I wonder how it affects performance? ”
It finishes me up. Almost always, I see the first question from developers about a new feature of the language. “Does it work fast?”
I think thinking about it is a waste of time. For your site, which has 100 visitors per day, yes, there is enough performance.
It’s better to ask a different question - “Is the application fast enough for my requirements?” And if not, then you should look for bottlenecks and optimize them. Your performance problems are in no way related to the language features, but to errors at a higher level, for example, as the Select N + 1 problem
5. Light at the end of the tunnel
“Oh, using the new item did not format my hard drive. Maybe it’s not so bad. ”
Now the developer begins to understand that the new functionality does not eat kittens for breakfast and is not the embodiment of the devil. Hey! It even has the right to legal use.
This is the stage at which you see a lot of experimentation with the new functionality, as developers are trying to figure out where it works well or vice versa.
6. The code got crazy
I think we all go through this phase from time to time. At some point, you realize that the new functionality is cool and you're happy as an elephant. The Thor's Hammer is in your hands and each line of code looks like a nail, ready to be hammered.
Many things can become ugly at this stage in a fit of excitement. Suddenly, every object is anonymous, every callback is a lambda expression and every method is generic, in any case, where it is needed and not needed.
It is probably a good idea to resist this, but at one point you give yourself freedom and enjoy the new language feature. Remember only one command.
svn revert –R
Or another alternative command from your favorite version control system.
7. Approval and forgetfulness.
At this stage, the developer has finally adopted new features in the language like any other part of the language, like class or public elements. There is no need to use it for no reason, or vice versa, wherever possible. The developer begins to use the functionality only where it is really needed.