In DEFINE-STANDARD-KEYWORD, pass a list of fragments to
authorTaylor R. Campbell <net/mumble/campbell>
Thu, 18 Jan 2007 02:15:05 +0000 (02:15 +0000)
committerTaylor R. Campbell <net/mumble/campbell>
Thu, 18 Jan 2007 02:15:05 +0000 (02:15 +0000)
DEFINE-KEYPARSER-PATTERN as one argument, not the fragments as
separate arguments.  This is supposed to be a `pattern' structure,
although it might be better to have an abstract MAKE-PATTERN
constructor or something instead of exposing the representation of
patterns as lists.

v7/src/edwin/verilog.scm

index 47c277f7dead4e49ec35d752d5083c07e872478e..4cb8cb4ed1a0428dc3851e67344a7a5b93620196 100644 (file)
@@ -1,6 +1,6 @@
 #| -*-Scheme-*-
 
-$Id: verilog.scm,v 1.14 2007/01/05 21:19:24 cph Exp $
+$Id: verilog.scm,v 1.15 2007/01/18 02:15:05 riastradh Exp $
 
 Copyright (C) 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
     1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
@@ -182,27 +182,28 @@ USA.
 
 (define (define-standard-keyword keyword end parse-header)
   (define-keyparser-pattern keyword verilog-description
-    (make-keyparser-fragment 'KEYWORD
-                            keyword
-                            'PARSE-HEADER
-                            parse-header
-                            'INDENT-HEADER
-                            continued-header-indent
-                            'PARSE-BODY
-                            keyparse-forward
-                            'INDENT-BODY
-                            continued-statement-indent)
-    (and end
-        (make-keyparser-fragment 'KEYWORD
-                                 end
-                                 'PARSE-HEADER
-                                 parse-forward-noop
-                                 'INDENT-HEADER
-                                 continued-header-indent
-                                 'PARSE-BODY
-                                 #f
-                                 'INDENT-BODY
-                                 #f))))
+    (list
+     (make-keyparser-fragment 'KEYWORD
+                             keyword
+                             'PARSE-HEADER
+                             parse-header
+                             'INDENT-HEADER
+                             continued-header-indent
+                             'PARSE-BODY
+                             keyparse-forward
+                             'INDENT-BODY
+                             continued-statement-indent)
+     (and end
+         (make-keyparser-fragment 'KEYWORD
+                                  end
+                                  'PARSE-HEADER
+                                  parse-forward-noop
+                                  'INDENT-HEADER
+                                  continued-header-indent
+                                  'PARSE-BODY
+                                  #f
+                                  'INDENT-BODY
+                                  #f)))))
 \f
 (define-standard-keyword "always" #f
   parse-forward-noop)