summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorandy <andrew.m.goth@gmail.com>2016-11-25 07:31:46 (GMT)
committerandy <andrew.m.goth@gmail.com>2016-11-25 07:31:46 (GMT)
commita3572d2400fc9b189ceb5f6f2c929486d136ab05 (patch)
tree490d820debff6d8b19ebf40ac93bc4515ccefd59 /tests
parent45f0dfd1a9fd6c3b5e3ca9a23da2cfedd364c1f7 (diff)
downloadtcl-a3572d2400fc9b189ceb5f6f2c929486d136ab05.zip
tcl-a3572d2400fc9b189ceb5f6f2c929486d136ab05.tar.gz
tcl-a3572d2400fc9b189ceb5f6f2c929486d136ab05.tar.bz2
Allow [array names -regexp] to use backreferences. This capability was broken by [71270e9141]. See also bug [1366683].
Diffstat (limited to 'tests')
-rw-r--r--tests/set-old.test7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/set-old.test b/tests/set-old.test
index 93169f1..309abaf 100644
--- a/tests/set-old.test
+++ b/tests/set-old.test
@@ -652,6 +652,13 @@ test set-old-8.52 {array command, array names -regexp on regexp pattern} {
set a(11) 1
list [catch {lsort [array names a -regexp ^1]} msg] $msg
} {0 {1*2 11 12}}
+test set-old-8.52.1 {array command, array names -regexp, backrefs} {
+ catch {unset a}
+ set a(1*2) 1
+ set a(12) 1
+ set a(11) 1
+ list [catch {lsort [array names a -regexp {^(.)\1}]} msg] $msg
+} {0 11}
test set-old-8.53 {array command, array names -regexp} {
catch {unset a}
set a(-glob) 1