Merge commit 'fdd319e9bd4121d844662d3d8ccc69b462b60840'
[bpt/guile.git] / module / scripts / snarf-check-and-output-texi.scm
index f92c833..82d71f4 100644 (file)
@@ -1,6 +1,6 @@
 ;;; snarf-check-and-output-texi --- called by the doc snarfer.
 
-;;     Copyright (C) 2001, 2002, 2006 Free Software Foundation, Inc.
+;; Copyright (C) 2001, 2002, 2006, 2011, 2014 Free Software Foundation, Inc.
 ;;
 ;; This program is free software; you can redistribute it and/or
 ;; modify it under the terms of the GNU Lesser General Public License
@@ -26,6 +26,9 @@
     :use-module (ice-9 match)
     :export (snarf-check-and-output-texi))
 
+(define %include-in-guild-list #f)
+(define %summary "Transform snarfed .doc files into texinfo documentation.")
+
 ;;; why aren't these in some module?
 
 (define-macro (when cond . body)
@@ -60,7 +63,7 @@
                                                (let loop ((s s))
                                                  (cond
                                                    ((stream-null? s) #t)
-                                                   ((eq? 'eol (stream-car s))
+                                                   ((memq (stream-car s) '(eol hash))
                                                     (loop (stream-cdr s)))
                                                    (else (cons (stream-car s) (stream-cdr s))))))
                                              (port->stream port read)))))
       (set! *file* file)
       (set! *line* line))
 
-     ;; newer gccs like to throw around more location markers into the
-     ;; preprocessed source; these (hash . hash) bits are what they translate to
-     ;; in snarfy terms.
-     (('location ('string . file) ('int . line) ('hash . 'hash))
-      (set! *file* file)
-      (set! *line* line))
-
-     (('location ('hash . 'hash) ('string . file) ('int . line) ('hash . 'hash))
-      (set! *file* file)
-      (set! *line* line))
-
      (('arglist rest ...)
       (set! *args* (do-arglist rest)))