Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : MMBasic Date$ possible bug
Author | Message | ||||
AndrewB Newbie Joined: 04/12/2011 Location: AustraliaPosts: 15 |
Hello all, I've just been testing a bit of code associated with timekeeping. One test I have done is to set the date$ and time$ to just before midnight at various month ends and leap years and non-leap years, with the following results: All non February months in leap years and non leap years roll over correctly from the end of one month to the next, updating the year as necessary. February in a leap year rolls over from 29-02-YYYY to 30-02-YYYY, so I think this is a bug. Should I submit this to the official support page? |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 6098 |
I can confirm the bug in MM Basic V3.1 > date$="29/02/2012"
> time$="23:59:30" > print date$;" ";time$ 29-02-2012 23:59:56 > print date$;" ";time$ 30-02-2012 00:00:16 > print mm.ver 3.01 Jim VK7JH MMedit MMBasic Help |
||||
Geoffg Guru Joined: 06/06/2011 Location: AustraliaPosts: 3194 |
Damn, I hate it when bugs turn up. Thanks folks, I will fix it in 3.2 (but probably too late for this leap day). Geoff Geoff Graham - http://geoffg.net |
||||
djuqa Guru Joined: 23/11/2011 Location: AustraliaPosts: 447 |
No RUSH then mate Next leapyear not for 4 years LOL VK4MU MicroController Units |
||||
AndrewB Newbie Joined: 04/12/2011 Location: AustraliaPosts: 15 |
Yep, no problem - I'll check for it in my code and cope with it that way. Cheers. |
||||
cosmic frog Senior Member Joined: 09/02/2012 Location: United KingdomPosts: 284 |
I think I may have also found a bug in the 'shorthand' Print statement. Print @(10,10)"hello" = ok ? @(10,10)"hello" = error |
||||
Geoffg Guru Joined: 06/06/2011 Location: AustraliaPosts: 3194 |
Thanks, you have found another one. Will be fixed in 3.2 Geoff P.S Love the user name !! Geoff Graham - http://geoffg.net |
||||
Print this page |