Skip to content
Tcl Source Code History Of Ticket 495213ffffffffff
Login

History Of Ticket 495213ffffffffff

Artifacts Associated With Ticket 495213ffffffffff

  1. Ticket change [85d1d59305] (rid 131385) by hemanglavana on 2001-12-19 22:55:37:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      Hemang,
      
      You have indeed found a bug in the scan command.  This occured
      when 'scan' was rewritten for 8.1 to support unicode.  The problem
      is rather simple - it won't read past the "0x...", so you are
      always scanning the 0 before the x.  You can see this with:
              scan 0x001 %xx%x
      =>      0 1
      
      The workaround is to do:
              set a [expr $a]
      
      and then the scan.  This does need to be reported to SourceForge
      as well.  Is this something that you will also need corrected in
      the IOS port?
      
      Thanks,
      
        Jeff Hobbs                     The Tcl Guy
        Senior Developer               http://www.ActiveState.com/
            Tcl Support and Productivity Solutions
      
      
      > -----Original Message-----
      > From: Hemang Lavana [mailto:[email protected]]
      > Sent: December 19, 2001 1:12 PM
      > To: [email protected]
      > Cc: [email protected]; [email protected]
      > Subject: Bug in scan command?
      > 
      > 
      > Hello Jeff,
      > 
      > Is this a bug in scan command? I tried these commands in tcl8.3.4.1
      > version on win2k and got the same results. Note that ATS3.2 contains
      > tcl8.0.5 version and ATS3.4 contains tcl8.3.3 version.
      > 
      > % package provide ActiveTcl
      > 8.3.4.1
      > (bin) 2 % set a 0x0001
      > 0x0001
      > (bin) 3 % scan $a %x a
      > 1
      > (bin) 4 % puts $a
      > 0
      > (bin) 5 % scan 0xff %x
      > 0
      > 
      > Let me know if you want me to file a bug on SF.
      > 
      > Thanks,
      > Hemang.
      
    4. foundin initialized to: "None"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "hemanglavana"
    9. subsystem initialized to: "None"
    10. title initialized to: "bug in scan command"
    11. type initialized to: "Bug"
  2. Ticket change [3f10e4ef9c] (rid 121386) by hobbs on 2001-12-20 06:19:54:

    1. assignee changed to: "hobbs"
    2. foundin changed to: "final: 8.1.1"
    3. priority changed to: "6"
  3. Ticket change [ad303a529b] (rid 101430) by hobbs on 2002-02-07 08:44:44:

    1. closedate changed to: "2002-02-07T01:44:44"
    2. closer changed to: "hobbs"
    3. icomment:
      
      
      File Added - 17391: 495213.patch
      
      Logged In: YES 
      user_id=72656
      
      oddly enough, scan-4.40 had a test that relied on the 
      incorrect behavior.  I have the feeling noone bothered to 
      check that the result was wrong, since it is inconsistent 
      with 8.0 and C's scanf.  Attached is the patch for 8.4a4cvs 
      that should apply to 8.3.4cvs as well (simple fix).
      
      
    4. login: "hobbs"
    5. mimetype: "text/plain"
    6. resolution changed to: "Fixed"
    7. status changed to: "Closed"
    8. username: "hobbs"
  4. Add attachment "495213.patch" [668e0b4ac9] (rid 102732) by hobbs on 2002-02-07 08:44:44.