diff options
author | twylite <twylite@crypt.co.za> | 2012-08-03 16:39:49 (GMT) |
---|---|---|
committer | twylite <twylite@crypt.co.za> | 2012-08-03 16:39:49 (GMT) |
commit | 8c5e0f4fee6b9a2fc04eba8af7461c422bf0f73a (patch) | |
tree | 6d4e5f813c3379eb7aebf2fa65aaf0e7fe13dbd3 /tests/foreach.test | |
parent | 4479d5c37372800e7b6b7d8c580f0d6479c6856f (diff) | |
download | tcl-8c5e0f4fee6b9a2fc04eba8af7461c422bf0f73a.zip tcl-8c5e0f4fee6b9a2fc04eba8af7461c422bf0f73a.tar.gz tcl-8c5e0f4fee6b9a2fc04eba8af7461c422bf0f73a.tar.bz2 |
[Patch-3163961] Implementation of TIP #405 merged from private branch. Includes 'mapeach', 'dict map' and 'foreacha' commands, test suite (partial for 'foreacha') and man pages (except for 'foreacha').
Diffstat (limited to 'tests/foreach.test')
-rw-r--r-- | tests/foreach.test | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/foreach.test b/tests/foreach.test index a4b652a..6c69b29 100644 --- a/tests/foreach.test +++ b/tests/foreach.test @@ -266,6 +266,15 @@ test foreach-10.1 {foreach: [Bug 1671087]} -setup { rename demo {} } -result {} +test foreach-11.1 {error then dereference loop var (dev bug)} { + catch { foreach a 0 b {1 2 3} { error x } } + set a +} 0 +test foreach-11.2 {error then dereference loop var (dev bug)} { + catch { foreach a 0 b {1 2 3} { incr a $b; error x } } + set a +} 1 + # cleanup catch {unset a} catch {unset x} |