Author Topic: A Bug or Not A Bug  (Read 434 times)

0 Members and 1 Guest are viewing this topic.

ronjonp

  • Needs a day job
  • Posts: 6278
Re: A Bug or Not A Bug
« Reply #15 on: August 03, 2017, 11:59:32 pm »
I'm running 2018 x64 and the rounding issue was there too.

Windows 10 x64 - AutoCAD /C3D 2018

Custom Build PC

MeasureUp

  • Bull Frog
  • Posts: 416
Re: A Bug or Not A Bug
« Reply #16 on: August 06, 2017, 07:03:29 pm »
Based on everyone's replies, I believe there is a bug with "getreal" function. (well, believe but not 100% sure) => this may be stated as (/= (getreal "100") 100.000%) :-D
In my other thread Lee points out that "rtos" is dependent upon the "dimzin" system variable.
Maybe Lee or someone else can find out a workaround for "getreal"?

BTW for my practice, I will do something like this:
(setq number1 (getreal "\n\nInput A Real: "))
; then redefine "number1"
(setq number1 (princ number1))

Then (= number1 5.123) returns "T".

VovKa

  • Swamp Rat
  • Posts: 781
  • Ukraine
Re: A Bug or Not A Bug
« Reply #17 on: August 06, 2017, 07:28:47 pm »
I believe there is a bug with "getreal" function.
not only getreal but all get* functions

i suspect that autodesk guys decided that get* functions and read/atof should use different techniques the parse the string
just to make life more fun :)

ronjonp

  • Needs a day job
  • Posts: 6278
Re: A Bug or Not A Bug
« Reply #18 on: August 06, 2017, 11:41:44 pm »
There are bugs er where .. fuzz value 😋

Windows 10 x64 - AutoCAD /C3D 2018

Custom Build PC

Lee Mac

  • Seagull
  • Posts: 11733
  • AutoCAD 2015 Windows 7 London, England
Re: A Bug or Not A Bug
« Reply #19 on: August 07, 2017, 01:02:40 pm »
Personally, I don't see that this is a problem. When working with doubles, it is known that rounding can occur at the nth decimal place as any non-integer value is expressed to a limited precision, therefore, providing that you always include a small tolerance when comparing doubles, this issue is not relevant.

My 2p.

Lee

MeasureUp

  • Bull Frog
  • Posts: 416
Re: A Bug or Not A Bug
« Reply #20 on: August 07, 2017, 08:09:40 pm »
I believe there is a bug with "getreal" function.
not only getreal but all get* functions

i suspect that autodesk guys decided that get* functions and read/atof should use different techniques the parse the string
just to make life more fun :)
Thanks for your reply. You opened another window for me. I never thought other get* functions have issues.

And thanks to Lee.

I may put aside this question/problem for now as I still suspect it would be a bug.
Again, I agree that a fuzz obviously gets rid of it but...

Thanks again for everyone's input - they are valuable.