📄 binary.test
字号:
test binary-23.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x82\x53 B arg1] $arg1} {1 1}test binary-23.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x82\x53 B1 arg1] $arg1} {1 1}test binary-23.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 B0 arg1] $arg1} {1 {}}test binary-23.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 B5 arg1] $arg1} {1 01010}test binary-23.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 B8 arg1] $arg1} {1 01010010}test binary-23.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 B14 arg1] $arg1} {1 01010010010100}test binary-23.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 B14 arg1] $arg1} {0 foo}test binary-23.10 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 B1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-23.11 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x70\x87\x05 B5B* arg1 arg2] $arg1 $arg2} {2 01110 1000011100000101}test binary-24.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc h} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-24.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 h* arg1] $arg1} {1 253a}test binary-24.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \xc2\xa3 h arg1] $arg1} {1 2}test binary-24.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x82\x53 h1 arg1] $arg1} {1 2}test binary-24.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 h0 arg1] $arg1} {1 {}}test binary-24.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \xf2\x53 h2 arg1] $arg1} {1 2f}test binary-24.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 h3 arg1] $arg1} {1 253}test binary-24.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 h3 arg1] $arg1} {0 foo}test binary-24.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 h1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-24.10 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x70\x87\x05 h2h* arg1 arg2] $arg1 $arg2} {2 07 7850}test binary-25.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc H} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-25.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 H* arg1] $arg1} {1 52a3}test binary-25.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \xc2\xa3 H arg1] $arg1} {1 c}test binary-25.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x82\x53 H1 arg1] $arg1} {1 8}test binary-25.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 H0 arg1] $arg1} {1 {}}test binary-25.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \xf2\x53 H2 arg1] $arg1} {1 f2}test binary-25.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\x53 H3 arg1] $arg1} {1 525}test binary-25.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 H3 arg1] $arg1} {0 foo}test binary-25.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 H1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-25.10 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x70\x87\x05 H2H* arg1 arg2] $arg1 $arg2} {2 70 8705}test binary-26.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc c} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-26.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 c* arg1] $arg1} {1 {82 -93}}test binary-26.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 c arg1] $arg1} {1 82}test binary-26.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 c1 arg1] $arg1} {1 82}test binary-26.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 c0 arg1] $arg1} {1 {}}test binary-26.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 c2 arg1] $arg1} {1 {82 -93}}test binary-26.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \xff c arg1] $arg1} {1 -1}test binary-26.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 c3 arg1] $arg1} {0 foo}test binary-26.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 c1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-26.10 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x70\x87\x05 c2c* arg1 arg2] $arg1 $arg2} {2 {112 -121} 5}test binary-27.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc s} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-27.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 s* arg1] $arg1} {1 {-23726 21587}}test binary-27.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 s arg1] $arg1} {1 -23726}test binary-27.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 s1 arg1] $arg1} {1 -23726}test binary-27.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 s0 arg1] $arg1} {1 {}}test binary-27.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 s2 arg1] $arg1} {1 {-23726 21587}}test binary-27.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 s1 arg1] $arg1} {0 foo}test binary-27.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 s1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-27.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x52\xa3\x53\x54\x05 s2c* arg1 arg2] $arg1 $arg2} {2 {-23726 21587} 5}test binary-28.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc S} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-28.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 S* arg1] $arg1} {1 {21155 21332}}test binary-28.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 S arg1] $arg1} {1 21155}test binary-28.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 S1 arg1] $arg1} {1 21155}test binary-28.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3 S0 arg1] $arg1} {1 {}}test binary-28.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 S2 arg1] $arg1} {1 {21155 21332}}test binary-28.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 S1 arg1] $arg1} {0 foo}test binary-28.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53 S1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-28.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x52\xa3\x53\x54\x05 S2c* arg1 arg2] $arg1 $arg2} {2 {21155 21332} 5}test binary-29.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc i} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-29.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 i* arg1] $arg1} {1 {1414767442 67305985}}test binary-29.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 i arg1] $arg1} {1 1414767442}test binary-29.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 i1 arg1] $arg1} {1 1414767442}test binary-29.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53 i0 arg1] $arg1} {1 {}}test binary-29.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 i2 arg1] $arg1} {1 {1414767442 67305985}}test binary-29.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 i1 arg1] $arg1} {0 foo}test binary-29.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53\x53\x54 i1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-29.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04\x05 i2c* arg1 arg2] $arg1 $arg2} {2 {1414767442 67305985} 5}test binary-30.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc I} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-30.2 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 I* arg1] $arg1} {1 {1386435412 16909060}}test binary-30.3 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 I arg1] $arg1} {1 1386435412}test binary-30.4 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54 I1 arg1] $arg1} {1 1386435412}test binary-30.5 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53 I0 arg1] $arg1} {1 {}}test binary-30.6 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04 I2 arg1] $arg1} {1 {1386435412 16909060}}test binary-30.7 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 foo list [binary scan \x52 I1 arg1] $arg1} {0 foo}test binary-30.8 {Tcl_BinaryObjCmd: scan} { catch {unset arg1} set arg1 1 list [catch {binary scan \x52\x53\x53\x54 I1 arg1(a)} msg] $msg} {1 {can't set "arg1(a)": variable isn't array}}test binary-30.9 {Tcl_BinaryObjCmd: scan} { catch {unset arg1 arg2} set arg1 foo set arg2 bar list [binary scan \x52\xa3\x53\x54\x01\x02\x03\x04\x05 I2c* arg1 arg2] $arg1 $arg2} {2 {1386435412 16909060} 5}test binary-31.1 {Tcl_BinaryObjCmd: scan} { list [catch {binary scan abc f} msg] $msg} {1 {not enough arguments for all format specifiers}}test binary-31.2 {Tcl_BinaryObjCmd: scan} {nonPortable macOrUnix} { catch {unset arg1} list [binary scan \x3f\xcc\xcc\xcd\x40\x59\x99\x9a f* arg1] $arg1} {1 {1.60000002384 3.40000009537}}test binary-31.3 {Tcl_BinaryObjCmd: scan} {nonPortable pcOnly} { catch {unset arg1} list [binary scan \xcd\xcc\xcc\x3f\x9a\x99\x59\x40 f* arg1] $arg1} {1 {1.60000002384 3.40000009537}}test binary-31.4 {Tcl_BinaryObjCmd: scan} {nonPortable macOrUnix} { catch {unset arg1} list [binary scan \x3f\xcc\xcc\xcd\x40\x59\x99\x9a f arg1] $arg1} {1 1.60000002384}test binary-31.5 {Tcl_BinaryObjCmd: scan} {nonPortable pcOnly} { catch {unset arg1} list [binary scan \xcd\xcc\xcc\x3f\x9a\x99\x59\x40 f arg1] $arg1} {1 1.60000002384}test binary-31.6 {Tcl_BinaryObjCmd: scan} {nonPortable macOrUnix} { catch {unset arg1} list [binary scan \x3f\xcc\xcc\xcd f1 arg1] $arg1} {1 1.60000002384}test binary-31.7 {Tcl_BinaryObjCmd: scan} {nonPortable pcOnly} { catch {unset arg1} list [binary scan \xcd\xcc\xcc\x3f f1 arg1] $arg1} {1 1.60000002384}test binary-31.8 {Tcl_BinaryObjCmd: scan} {nonPortable macOrUnix} {
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -