Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Any properly defined software should take a date that doesn't exist and move it forward or backward to a date that does. Leap years would crash every computer every February if that wasn't taken into account.


Except that the whole February/leap year case is part of the Gregorian calendar. Moving the date forward or backward to a date that does exist is not a set rule and would only cause unnecessary confusion for a user or other developer for that matter; even worse if you were to do it without notifying the user. Wouldn't you agree that it'd just be better to catch the error and tell the user they "done messed up"?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: