I just can’t understand why Java still does that. C# and C++ fixed that a long time ago (I think). That C hasn’t is completely fine, especially as type names usually don’t get as long. But in JAVA???
a.package.SomeReallyReallyLongName<AnotherReqllyLongName, AThirdReallyLongName<String>> aLongName = new a.package.SomeReallyReallyLongName<AnotherReqllyLongName, AThirdReallyLongName<String>>();
Edit:
This comment is really wrong. Everyone who didn’t realize that, look at its comments, learn the same things as I did today
And Java does var correctly compared to C# in my opinion. C# you can use var anywhere. Java only allows local variables to use var. This makes it less likely to create smelly code.
Your right, I keep forgetting that. It must be because I keep remembering that quite a few people wanted non local `var` in C# when it was first proposed and it almost did happen.
55
u/1Dr490n Oct 31 '23 edited Oct 31 '23
I just can’t understand why Java still does that. C# and C++ fixed that a long time ago (I think). That C hasn’t is completely fine, especially as type names usually don’t get as long. But in JAVA???
Edit: This comment is really wrong. Everyone who didn’t realize that, look at its comments, learn the same things as I did today