Overview
| Artifact ID: | 68693be7f433bc1f1dfe4fc6e0d9ac17c363c21e |
|---|---|
| Ticket: | 1275043fffffffffffffffffffffffffffffffff
expr round(0.5) returns no more 1 |
| User & Date: | sarnold75 on 2005-08-28 08:58:31 |
Changes
- assignee changed to: "dkf"
- cmimetype changed to: "text/plain"
- comment changed to:
--- Environment --- WindowsME and Tcl 8.5a4 built with MingW --- Example of code --- With Tcl8.4 (and even 8.5a3) : expr round(0.5) --> 1 expr round(-0.5) --> -1 With the new 8.5a4 : expr round(0.5) --> 0 expr round(-0.5) --> 0 --- Discussion --- I have been told that now the new functionality is to round to even numbers. The reason for this bug report is that the tcllib's math::bigfloat package used to test the bigfloat round command against the builtin [expr round()]. It does no more, because I hand-coded the attempted result as 1 or -1. But I would like to know at least one example where the round function we are used to causes a bug. Then, I could want to implement the same behavior in my package.
- foundin changed to: "None"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "sarnold75"
- subsystem changed to: "16. Commands A-H"
- title changed to: "expr round(0.5) returns no more 1"
- type changed to: "Bug"