Wrong Notation of Tick value

Zenerdiode

Active Member
Licensed User
I apologise if I have posted this in the wrong forum; I don't know if it is a bug or not. I'm manipulating tick values to place time stamps in a file. All my work in the IDE and non-Optimised compilation stores the tick value in full, however once compiled with optimised compilation, the tick values are stored in E scientific notation.

This then causes problems when evaluating and comparing values. Again I've stripped out all my project and provided a simple .sbp to show. Compile and build an optimised compilation and then either use the IDE or compile a non optimised version, store a tick value and then check it in both versions with the 'Stored Correctly?' button. Then try vice versa.

I'd prefer to have the tick value stored in full...

Many Thanks,

Christopher
 

specci48

Well-Known Member
Licensed User
Hi Zenerdiode,

I modified your code so that the comparision works always fine, even with optimized compilation. The trick I used is to store the DateParse value into a decimal variable before saving or comparing it.

Maybe this can only be called a workaround, but hey... ;)


Cheers
specci48

Edit: As usual, no change to be faster than Erel... :sign0161:
 

Zenerdiode

Active Member
Licensed User
Many thanks to both of you. I genuinely appreciate the help all are giving to me in the early stages of learning Basic4ppc. I can't help but feel all my posts are a little one-sided at the moment - i.e. I'm asking all the questions and you lot are providing almost instant answers!
 

specci48

Well-Known Member
Licensed User
...i.e. I'm asking all the questions and you lot are providing almost instant answers!
There's no problem with that! Because without these questions were wouldn't have thoses wonderful small "races", if we can answer a question faster than Erel... :sign0060: Even he has to correct us sometimes or gives a much more precisely answer. :sign0027:
 
Top