Bug in MetaEditor Build 3566: Wrong display of double floating point numbers in the debugger window - page 3

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I have to think every time which "short" number is in the equivalence group.
For example, it is not clear to me which of these numbers is greater or less than 0.3.
Displaying strings at maximum accuracy (17 s.f) for doubles hurts, because the format cannot represent real numbers very accurately. So, a shortest precise string hides those tiny representation errors from the user, and at the same time preserves the accuracy (roundtrip string -> double).
Even for the experienced programmers!
That is why Microsoft debugger adopted the shortest form, although the longest 17 significant digits (%.17g) is extremely accurate.although the longest 17 significant digits (%.17g) is extremely accurate.
They are not accurate, because are equal to (min+max)/2 of their equivalence group.
Display the binary value, do not get confused by the debugger output. This is a side effect of the %.17g display. You can re-test with Print().
In general, there were enough arguments in favor of the fact that the debugger should show the "shortest" number from its equivalence group, and not the average.
Yes it is the average: as equivalence group extends from representable floating point number +/- half epsilon on both directions. The representable fp number lies in the middle of the group.
I am facing the same resistance for change :-) like the first time I reported the bug in string conversion before. Now, the display of doubles from Print(), string(), Alert(), FileWrite() and dialogue boxes are fixed.
I will not add more to this post.
Thanks fxsaber!
Thanks fxsaber!
I am also grateful to you, because You proved me wrong in the first place.