News for hackers. Stuff that matters.
Re:Worst Bug Ever by TeMPOraL on Monday January 21, 2013 @11:02AM (#5092002)
Or just make it not mutable. Throw a big, fat error when someone assigns value to i.
Re:Worst Bug Ever by chimeracoder on Monday January 21, 2013 @12:05PM (#5092315)
Or better yet, do what Python does. Require a constant in front of the 'i', even if it's only '1'. Since identifiers can't begin with a numeral, there's no way to shadow a valid use of a complex number this way.
Re:Worst Bug Ever by pfortuny on Monday January 21, 2013 @12:53PM (#5092656)
This would have been the best way to learn it, some kind of 'CRASH Eh! MAN your files have been formatted and all this project has been deleted because

i=sqrt(-1)

Sorry for the mess, hope you learn from this...'

But I keep tripping over the same stone...

Re:Worst Bug Ever by KMag on Wednesday January 23, 2013 @10:14AM (#5103385)
Presumably the parent meant to throw an exception and show a script-level stack trace, not silently exit with no diagnostic messages.

Insisting on doing something, even if it's the wrong thing, is much worse in most applications than refusing to run in order to avoid producing incorrect and misleading results.