On Tue, May 3, 2011 at 8:50 AM, Kirk <[email protected]> wrote:
> As much as I respect the man, I still say that said, Hungarian notation is
> wrong. The bastardization that came from his first description is also
> wrong.
>
You speak as someone who never wrote code before Java, and I know that's not
the case.
Anyone who has written some C/C++ code (especially Windows code) knows
better. Hungarian Notation (even its misunderstood version, as I pointed
out) was quite useful back in the days where IDE's and compilers were not as
powerful as they are today.
It is admittedly much less useful today but, as I pointed out again, still
lives in some more healthy ways. Here is another example:
String fileName = "...";
File file = new File(fileName);
You don't realize it, but you just used Hungarian Notation. With the names
you just chose, you will be able to quickly read code that uses these
variables and immediately notice if something is wrong, such as:
if (fileName.exists()) { ... }
You don't need an IDE to tell you something is wrong here, thanks to
Hungarian Notation.
--
Cédric
--
You received this message because you are subscribed to the Google Groups "The
Java Posse" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/javaposse?hl=en.