From ffc636c69c87660a447b2d9aa90aa43acd965c7d Mon Sep 17 00:00:00 2001
From: Chris Hanson <org/chris-hanson/cph>
Date: Mon, 5 Feb 2001 21:47:30 +0000
Subject: [PATCH] Grumble.  Messing around while debugging problems caused by
 incorrectly built bands.

---
 v7/src/runtime/rgxcmp.scm | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/v7/src/runtime/rgxcmp.scm b/v7/src/runtime/rgxcmp.scm
index f9155c934..3e82d3637 100644
--- a/v7/src/runtime/rgxcmp.scm
+++ b/v7/src/runtime/rgxcmp.scm
@@ -1,6 +1,6 @@
 ;;; -*-Scheme-*-
 ;;;
-;;; $Id: rgxcmp.scm,v 1.111 2001/02/05 20:08:15 cph Exp $
+;;; $Id: rgxcmp.scm,v 1.112 2001/02/05 21:47:30 cph Exp $
 ;;;
 ;;; Copyright (c) 1986, 1989-2001 Massachusetts Institute of Technology
 ;;;
@@ -666,20 +666,20 @@
       (let loop
 	  ((chars
 	    (if (input-match? (input-peek) #\])
-		(list (input-read!))
+		(begin (input-discard!) '(#\]))
 		'())))
 	(if (input-end?)
 	    (premature-end))
-	(if (input-match? (input-peek) #\])
-	    (begin
-	      (input-discard!)
-	      (for-each
-	       (lambda (char)
-		 ((ucode-primitive re-char-set-adjoin!) charset
-							(char->ascii char)))
-	       (char-set-members
-		(re-compile-char-set (list->string (reverse! chars)) #f))))
-	    (loop (cons (input-read!) chars))))
+	(let ((char (input-read!)))
+	  (if (input-match? char #\])
+	      (begin
+		(for-each
+		 (lambda (char)
+		   ((ucode-primitive re-char-set-adjoin!) charset
+							  (char->ascii char)))
+		 (char-set-members
+		  (re-compile-char-set (list->string (reverse! chars)) #f))))
+	      (loop (cons char chars)))))
       (output-start! (if invert? re-code:not-char-set re-code:char-set))
       ;; Discard any bitmap bytes that are all 0 at the end of
       ;; the map.  Decrement the map-length byte too.
-- 
2.25.1