Skip to content
Tcl Source Code View Ticket
Login

View Ticket

new 'NaN' expr tests fail on Windows

Closed / Out of Date589012ffffffffffffffffffffffffffffffffffCreated 24 years agoUpdated 24 years ago
Descriptionplain2002-07-31 09:32:09
exec.test

==== exec-18.1 exec cat deals with weird file 
names FAILED
==== Contents of test case:

    set f "foo\[\{blah"
    set path(fooblah) [makeFile {} $f]
    set fout [open $path(fooblah) w]
    puts $fout "contents"
    close $fout
    set res [list [catch {exec cat $path(fooblah)} msg] 
$msg]
    removeFile $f
    set res

---- Result was:
1 {/usr/bin/cat: C:/Tcl-source/tcl8.4/win/foo[\: 
No such file or directory}
---- Result should have been (exact matching):
0 contents
==== exec-18.1 FAILED

execute.test
expr-old.test
expr.test

==== expr-22.1 non-numeric floats FAILED
==== Contents of test case:

    list [catch {expr {NaN + 1}} msg] $msg

---- Result was:
1 {syntax error in expression "NaN + 1": variable 
references require preceding $
}
---- Result should have been (exact matching):
1 {domain error: argument not in valid range}
==== expr-22.1 FAILED


==== expr-22.2 non-numeric floats FAILED
==== Contents of test case:

    list [catch {expr {Inf + 1}} msg] $msg

---- Result was:
1 {syntax error in expression "Inf + 1": variable 
references require preceding $
}
---- Result should have been (exact matching):
1 {can't use infinite floating-point value as operand 
of "+"}
==== expr-22.2 FAILED


==== expr-22.3 non-numeric floats FAILED
==== Contents of test case:

    set nan NaN
    list [catch {expr {$nan + 1}} msg] $msg

---- Result was:
1 {can't use non-numeric floating-point value as 
operand of "+"}
---- Result should have been (exact matching):
1 {domain error: argument not in valid range}
==== expr-22.3 FAILED


==== expr-22.5 non-numeric floats FAILED
==== Contents of test case:

    list [catch {expr NaN} msg] $msg

---- Result was:
1 {syntax error in expression "NaN": variable 
references require preceding $}
---- Result should have been (exact matching):
1 {domain error: argument not in valid range}
==== expr-22.5 FAILED


==== expr-22.6 non-numeric floats FAILED
==== Contents of test case:

    list [catch {expr Inf} msg] $msg

---- Result was:
1 {syntax error in expression "Inf": variable 
references require preceding $}
---- Result should have been (exact matching):
1 {floating-point value too large to represent}
==== expr-22.6 FAILED


==== expr-22.7 non-numeric floats FAILED
==== Contents of test case:

    list [catch {expr {1 / NaN}} msg] $msg

---- Result was:
1 {syntax error in expression "1 / NaN": variable 
references require preceding $
}
---- Result should have been (exact matching):
1 {domain error: argument not in valid range}
==== expr-22.7 FAILED
dkf Closed ticket [589012ffff]. [History diff]2002-07-31 16:42:47
Log in (anonymous is fine) to add a comment.