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

I once inherited a project that had three separate classes for storing time, each with their own methods to convert between each other.


I can think of reasons for this (e.g. storing date/time as it was originally represented 100, 1000 years ago in a historical context vs storing live time for present-day time calculations vs storing non-timezone time for, say, operating hours relative to subject's location), so this statement alone doesn't show fault.


Fair enough. All three were for the same (live, present day) timestamp, and sometimes used within the same function, eg "timeb = timea+timec" where timea would be one class, and timeb and timec would be another.




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

Search: