[BUG-v6b7] MY_BIGNUM <> ValD(#MY_BIGNUM)

Found an issue in the documentation ? Please report it here !

Moderator: Documentation Editors

User avatar
skywalk
Addict
Addict
Posts: 3972
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

[BUG-v6b7] MY_BIGNUM <> ValD(#MY_BIGNUM)

Post by skywalk »

Why are DOUBLE numeric assignments <> ValD("same number")?
Can the compiler make them more equivalent?
For very large numbers this is a big error.

Code: Select all

rs = 24
#MY_CONST = 9.9e37
MY_CONSTv.d = 9.9e37
r$ = "9.9e37"
Debug "9.9e37   = " + LSet(StrD(ValD(r$),16),rs)
Debug "#9.9e37  = " + LSet(StrD(#MY_CONST,16),rs)
Debug "DIFF     = " + LSet(StrD(ValD(r$) - #MY_CONST,16),rs)
Debug "9.9e37   = " + LSet(StrD(ValD(r$),16),rs)
Debug "v9.9e37  = " + LSet(StrD(MY_CONSTv,16),rs)
Debug "DIFFv    = " + LSet(StrD(ValD(r$) - MY_CONSTv,16),rs)
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
User avatar
Andre
PureBasic Team
PureBasic Team
Posts: 2056
Joined: Fri Apr 25, 2003 6:14 pm
Location: Germany (Saxony, Deutscheinsiedel)
Contact:

Re: [BUG-v6b7] MY_BIGNUM <> ValD(#MY_BIGNUM)

Post by Andre »

Is this really a documentation issue? Or more a compiler behaviur, which should be checked by Fred.... anyway an answer of Fred is needed here I think....
Bye,
...André
(PureBasicTeam::Docs & Support - PureArea.net | Order:: PureBasic | PureVisionXP)
Post Reply