diff options
author | Kevin B Kenny <kennykb@acm.org> | 2005-05-10 20:17:28 (GMT) |
---|---|---|
committer | Kevin B Kenny <kennykb@acm.org> | 2005-05-10 20:17:28 (GMT) |
commit | 2bfc68501866a3efdbc3da722c3968f8ce0004ec (patch) | |
tree | 44715e3214b51e3cda135dcf59337464d7960aa1 /tests/binary.test | |
parent | 1fa3f8714cf2fac0c01da703897397454a410d9b (diff) | |
download | tcl-2bfc68501866a3efdbc3da722c3968f8ce0004ec.zip tcl-2bfc68501866a3efdbc3da722c3968f8ce0004ec.tar.gz tcl-2bfc68501866a3efdbc3da722c3968f8ce0004ec.tar.bz2 |
Fixes for C++-style comment and bad NaN on PA-RISC
Diffstat (limited to 'tests/binary.test')
-rw-r--r-- | tests/binary.test | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/tests/binary.test b/tests/binary.test index 047f80f..fb934d8 100644 --- a/tests/binary.test +++ b/tests/binary.test @@ -10,7 +10,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: binary.test,v 1.19 2005/05/10 18:34:56 kennykb Exp $ +# RCS: @(#) $Id: binary.test,v 1.20 2005/05/10 20:17:43 kennykb Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -1932,25 +1932,6 @@ test binary-57.9 {Tcl_BinaryObjCmd: scan} bigEndian { list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04\x05 n2c* arg1 arg2] $arg1 $arg2 } {2 {1386435412 16909060} 5} -# scan m -test binary-60.1 {Tcl_BinaryObjCmd: scan wide int} bigEndian { - binary scan HelloTcl m x - set x -} 5216694956358656876 -test binary-60.2 {Tcl_BinaryObjCmd: scan wide int} littleEndian { - binary scan lcTolleH m x - set x -} 5216694956358656876 -test binary-60.3 {Tcl_BinaryObjCmd: scan wide int with bit 31 set} littleEndian { - binary scan [binary format w [expr {wide(3) << 31}]] m x - set x -} 6442450944 -test binary-60.4 {Tcl_BinaryObjCmd: scan wide int with bit 31 set} bigEndian { - binary scan [binary format W [expr {wide(3) << 31}]] m x - set x -} 6442450944 - - # scan Q/q test binary-58.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc q} msg] $msg @@ -2085,11 +2066,30 @@ test binary-59.15 {Tcl_BinaryObjCmd: scan} littleEndian { list [binary scan \xcd\xcc\xcc\x3f\x9a\x99\x59\x40\x05 r2c* arg1 arg2] $arg1 $arg2 } {2 {1.600000023841858 3.4000000953674316} 5} -test binary-60.1 {[binary format] with NaN} { +test binary-60.1 {[binary format] with NaN} -body { binary scan [binary format dqQfrR NaN NaN NaN NaN NaN NaN] dqQfrR \ v1 v2 v3 v4 v5 v6 list $v1 $v2 $v3 $v4 $v5 $v6 -} {NaN NaN NaN NaN NaN NaN} +} -match regexp -result {NaN(\([[:xdigit:]]+\))? NaN(\([[:xdigit:]]+\))? NaN(\([[:xdigit:]]+\))? NaN(\([[:xdigit:]]+\))? NaN(\([[:xdigit:]]+\))? NaN(\([[:xdigit:]]+\))?} + +# scan m +test binary-61.1 {Tcl_BinaryObjCmd: scan wide int} bigEndian { + binary scan HelloTcl m x + set x +} 5216694956358656876 +test binary-61.2 {Tcl_BinaryObjCmd: scan wide int} littleEndian { + binary scan lcTolleH m x + set x +} 5216694956358656876 +test binary-61.3 {Tcl_BinaryObjCmd: scan wide int with bit 31 set} littleEndian { + binary scan [binary format w [expr {wide(3) << 31}]] m x + set x +} 6442450944 +test binary-61.4 {Tcl_BinaryObjCmd: scan wide int with bit 31 set} bigEndian { + binary scan [binary format W [expr {wide(3) << 31}]] m x + set x +} 6442450944 + # cleanup ::tcltest::cleanupTests |