From 6cbfdcc4a338d5b7348ee7e65a7710d13f9bc27e Mon Sep 17 00:00:00 2001 From: pooryorick Date: Sat, 23 Jun 2018 14:18:06 +0000 Subject: Add a test for no generation of a string representation when comparing with the empty string. --- tests/expr.test | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/expr.test b/tests/expr.test index fd11870..a265ac6 100644 --- a/tests/expr.test +++ b/tests/expr.test @@ -7196,6 +7196,15 @@ test expr-51.1 {test round-to-even on input} { expr 6.9294956446009195e15 } 6929495644600920.0 +test expr-52.1 { + comparison with empty string does not generate string representation +} { + set a [list one two three] + list [expr {$a eq {}}] [expr {$a < {}}] [expr {$a > {}}] [ + string match {*no string representation*} [ + ::tcl::unsupported::representation $a]] +} {0 0 1 1} + # cleanup -- cgit v0.12