Mercurial > hg > xemacs-beta
changeset 2324:df2fafa399a1
[xemacs-hg @ 2004-10-07 08:01:41 by stephent]
test for shy groups counted in registers bug
<87vfdnx8n7.fsf@tleepslib.sk.tsukuba.ac.jp>
author | stephent |
---|---|
date | Thu, 07 Oct 2004 08:01:44 +0000 |
parents | dc1c909a7a15 |
children | 9d8bfee6e672 |
files | tests/ChangeLog tests/automated/regexp-tests.el |
diffstat | 2 files changed, 20 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/ChangeLog Wed Oct 06 21:51:33 2004 +0000 +++ b/tests/ChangeLog Thu Oct 07 08:01:44 2004 +0000 @@ -1,3 +1,8 @@ +2004-10-07 Stephen J. Turnbull <stephen@xemacs.org> + + * automated/regexp-tests.el: Add tests for bug identified by + Steve Youngs 2004-09-30 <microsoft-free.87ekkjhj7t.fsf@youngs.au.com> + 2004-09-08 Stephen J. Turnbull <stephen@xemacs.org> * automated/regexp-tests.el: Add tests for bug identified by
--- a/tests/automated/regexp-tests.el Wed Oct 06 21:51:33 2004 +0000 +++ b/tests/automated/regexp-tests.el Thu Oct 07 08:01:44 2004 +0000 @@ -408,3 +408,18 @@ (Assert (eq 0 (string-match "^\\(?:a\\)*b" text))) ; 0 ) +;; per Steve Youngs 2004-09-30 <microsoft-free.87ekkjhj7t.fsf@youngs.au.com> +;; fix submitted by sjt 2004-10-07 +;; trailing comments are values from buggy 21.4.pre16 +(let ((text "abc")) + (Assert (eq 0 (string-match "\\(?:a\\(b\\)\\)" text))) ; 0 + (Assert (string= (match-string 1 text) "b")) ; ab + (Assert (null (match-string 2 text))) ; b + (Assert (null (match-string 3 text))) ; nil + (Assert (eq 0 (string-match "\\(?:a\\(?:b\\(c\\)\\)\\)" text))) ; 0 + (Assert (string= (match-string 1 text) "c")) ; abc + (Assert (null (match-string 2 text))) ; ab + (Assert (null (match-string 3 text))) ; c + (Assert (null (match-string 4 text))) ; nil +) +