Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 7f055435ec2b2b71bfd033e132e9f6d947b5548767ee788781f1dd305af0c6cb
Ticket: b8e9a9a97f0d8be15bd549239ec89aa58c11f3f4
expr 52 * 0.001 = 0.052000000000000005
User & Date: anonymous on 2019-03-08 23:00:38
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    It seems the number 52 is not handled correctly. See the math example below. 
    52 * 0.001 = 0.052000000000000005
    0.52 * 0.01 = 0.005200000000000001
    
    I can reproduce this issue in Tcl 8.6.8 for Windows and Tcl 8.5.9 for Windows.
    
    (bin) 1 % expr 1 + 3
    4
    (bin) 2 % expr 52 + 3
    55
    (bin) 3 % expr 52 * 0.01
    0.52
    (bin) 4 % expr 52 * 0.001
    0.052000000000000005
    (bin) 5 % expr 0.52 * 0.01
    0.005200000000000001
    
  5. foundin changed to: "Tcl 8.6.8 for Windows"
  6. is_private changed to: "0"
  7. login: "anonymous"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "69a9682e5af36190bd20b47267a61c36b8a00759"
  10. resolution changed to: "None"
  11. severity changed to: "Critical"
  12. status changed to: "Open"
  13. submitter changed to: "anonymous"
  14. subsystem changed to: "48. Number Handling"
  15. title changed to: "expr 52 * 0.001 = 0.052000000000000005"
  16. type changed to: "Bug"