The “var” declaration does not belong ANYWHERE near C#, it is a travesty as far as I am concerned that it got into the C# language. The use of "var" is NOT strongly typed and therefore should not be in managed code. It is for lazy people who are still in love with shitty unstructured coding practices like VB, VBScript or VB.Net.
The "var"/"dim" and other symbols are okay to use when scripting, like in JavaScript or python. The reason being you really don't know 100% what your inputs are or what to expect. I know I listed VBScript above but that is because VBScript is crap and should be sealed away in history never to rise again, objective c can join it.
Scripting is pseudo programming, which is not a stab at scripters, I script frequently. I am just saying don't port it over to managed code and try to pass it off as good practice. They are different, keep the seperation.
No comments:
Post a Comment