Programming complaint/whine
Sep. 22nd, 2004 12:21 pmHave been working on a little personal programming project that involves generating HTML and had a bug that brought up one of my pet peeves. There was a mistake in my generated HTML, due to a bug in my generator code. The browser (in this case FireFox) simply ignores the error, and more or less renders a page anyhow. I can never figure out why ignoring errors and possibly/probably doing the wrong thing is helpful. There are HTML checkers out there, but I hate that the default behavior of most things is to hide errors.
This also reminds me of my one of my biggest complaints with programming. Many otherwise reasonable programming languages (Perl, VB, REXX, many, many others) allow undeclared variables by default. While this can usually be turned off one way or another, this is another case of hiding errors. If I mis-spell a variable name, it sure is a lot better to get a syntax error like: "you did not declare foo" then for the language to hide it from me by creating an undeclared/uninitialized variable, and then leaving either a runtime crash or a "does the wrong thing" error. I can never figure out why language designers think this is good thing.
This also reminds me of my one of my biggest complaints with programming. Many otherwise reasonable programming languages (Perl, VB, REXX, many, many others) allow undeclared variables by default. While this can usually be turned off one way or another, this is another case of hiding errors. If I mis-spell a variable name, it sure is a lot better to get a syntax error like: "you did not declare foo" then for the language to hide it from me by creating an undeclared/uninitialized variable, and then leaving either a runtime crash or a "does the wrong thing" error. I can never figure out why language designers think this is good thing.