@@ -128,7 +128,7 @@ test expr-old-2.35 {floating-point operators} {expr 3.3||0.0} 1
128128test expr-old-2.36 {floating-point operators} {expr 3.3>2.3?44.3:66.3} 44.3
129129test expr-old-2.37 {floating-point operators} {expr 2.3>3.3?44.3:66.3} 66.3
130130test expr-old-2.38 {floating-point operators} {
131- list [catch {expr 028.1 + 09.2} msg] $msg
131+ list [catch {expr { 028.1 + 09.2} } msg] $msg
132132} {0 37.3}
133133
134134# Operators that aren't legal on floating-point numbers
@@ -553,7 +553,7 @@ test expr-old-30.2 {long values} {
553553# Expressions spanning multiple arguments
554554
555555test expr-old-31.1 {multiple arguments to expr command} {
556- expr 4 + ( 6 *12) -3
556+ expr { 4 + ( 6 *12) -3}
557557} 73
558558test expr-old-31.2 {multiple arguments to expr command} {
559559 list [catch {expr 2 + (3 + 4} msg]
@@ -577,7 +577,7 @@ test expr-old-32.3 {math functions in expressions} mathfunc {
577577 format %.6g [expr atan(1.0)]
578578} {0.785398}
579579test expr-old-32.4 {math functions in expressions} mathfunc {
580- format %.6g [expr atan2(2.0, 2.0)]
580+ format %.6g [expr { atan2(2.0, 2.0)} ]
581581} {0.785398}
582582test expr-old-32.5 {math functions in expressions} mathfunc {
583583 format %.6g [expr ceil(1.999)]
@@ -598,10 +598,10 @@ test expr-old-32.10 {math functions in expressions} mathfunc {
598598 format %.6g [expr floor(2.001)]
599599} {2}
600600test expr-old-32.11 {math functions in expressions} expr_fmod {
601- format %.6g [expr fmod(7.3, 3.2)]
601+ format %.6g [expr { fmod(7.3, 3.2)} ]
602602} {0.9}
603603test expr-old-32.12 {math functions in expressions} expr_hypot {
604- format %.6g [expr hypot(3.0, 4.0)]
604+ format %.6g [expr { hypot(3.0, 4.0)} ]
605605} {5}
606606test expr-old-32.13 {math functions in expressions} mathfunc {
607607 format %.6g [expr log(2.8)]
@@ -610,7 +610,7 @@ test expr-old-32.14 {math functions in expressions} mathfunc {
610610 format %.6g [expr log10(2.8)]
611611} {0.447158}
612612test expr-old-32.15 {math functions in expressions} mathfunc {
613- format %.6g [expr pow(2.1, 3.1)]
613+ format %.6g [expr { pow(2.1, 3.1)} ]
614614} {9.97424}
615615test expr-old-32.16 {math functions in expressions} mathfunc {
616616 format %.6g [expr sin(.1)]
@@ -692,7 +692,7 @@ test expr-old-32.38 {math functions in expressions} {
692692# list [catch {expr round(-1e60)} msg] $msg
693693#} {1 {integer value too large to represent}}
694694test expr-old-32.41 {math functions in expressions} mathfunc {
695- list [catch {expr pow(1.0 + 3.0 - 2, .8 * 5)} msg] $msg
695+ list [catch {expr { pow(1.0 + 3.0 - 2, .8 * 5)} } msg] $msg
696696} {0 16.0}
697697if {1} {
698698test expr-old-32.42 {math functions in expressions} expr_hypot {
@@ -702,7 +702,7 @@ test expr-old-32.43 {math functions in expressions} mathfunc {
702702 expr {pow(1.0 + 3.0, -2)}
703703} {0.0625}
704704test expr-old-32.45 {math functions in expressions} {
705- expr (0 <= rand()) && (rand() < 1)
705+ expr { (0 <= rand()) && (rand() < 1)}
706706} {1}
707707test expr-old-32.46 {math functions in expressions} -body {
708708 expr rand(24)
@@ -719,7 +719,7 @@ test expr-old-32.49 {math functions in expressions} -body {
719719} -returnCodes error -match glob -result *
720720test expr-old-32.50 {math functions in expressions} mathfunc {
721721 for {set i 0} {$i < 10} {incr i} {
722- lappend result [expr round(sin($i) * 1000)]
722+ lappend result [expr { round(sin($i) * 1000)} ]
723723 }
724724 set result
725725} {0 841 909 141 -757 -959 -279 657 989 412}
@@ -728,13 +728,13 @@ test expr-old-32.51 {math functions in expressions} -body {
728728} -returnCodes error -match glob -result *
729729
730730test expr-old-33.1 {conversions and fancy args to math functions} expr_hypot {
731- expr hypot ( 3 , 4 )
731+ expr { hypot ( 3 , 4 )}
732732} 5.0
733733test expr-old-33.2 {conversions and fancy args to math functions} expr_hypot {
734- expr hypot ( (2.0+1.0) , 4 )
734+ expr { hypot ( (2.0+1.0) , 4 )}
735735} 5.0
736736test expr-old-33.3 {conversions and fancy args to math functions} expr_hypot {
737- expr hypot ( 3 , (3.0 + 1.0) )
737+ expr { hypot ( 3 , (3.0 + 1.0) )}
738738} 5.0
739739test expr-old-33.4 {conversions and fancy args to math functions} mathfunc {
740740 format %.6g [expr cos(acos(0.1))]
0 commit comments