Summary: | Handle negative, FP numbers with non-10 radix in toString | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Maks Orlovich <maksim> | ||||
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | ||||||
Priority: | P2 | ||||||
Version: | 420+ | ||||||
Hardware: | Other | ||||||
OS: | Linux | ||||||
Attachments: |
|
Description
Maks Orlovich
2005-12-27 13:57:31 PST
Created attachment 5309 [details]
patch
Comment on attachment 5309 [details] patch I'll grant review because I think it's better to have this change than not. However: > + const double eps = 0.001; // TODO: guessed. base on radix ? That seems like a pretty high value for epsilon. > int(d) > double(radix) (in various places) - it would be better to avoid this cast syntax for numbers, I think. In some cases I think it is unnecesary, in other cases a normal c-style cast or assigning first to a variable of the appropriate type would be better. I think these improvements can be made in a separate pass though. |