~peter-pearse/ubuntu/natty/guile-1.8/prop001

« back to all changes in this revision

Viewing changes to debian/patches/doc-new-gcc.diff

  • Committer: Bazaar Package Importer
  • Author(s): Colin Watson
  • Date: 2011-02-17 14:19:09 UTC
  • Revision ID: james.westby@ubuntu.com-20110217141909-3no47zjqssyolsnb
Tags: 1.8.7+1-3ubuntu3
* Backport from upstream:
  - Be more accepting of source location markers in the preprocessed
    source, by adding a couple cases in which they can appear.  Not
    foolproof, but it does adapt to what new GCCs are putting out.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
From: Andy Wingo <wingo@oblong.net>
 
2
Date: Sun, 17 Jan 2010 17:22:51 +0000 (+0100)
 
3
Subject: fix doc snarfing with fedora 12
 
4
 
 
5
fix doc snarfing with fedora 12
 
6
 
 
7
* module/scripts/snarf-check-and-output-texi.scm
 
8
  (process-multiline-directive): Be more accepting of source location
 
9
  markers in the preprocessed source, by adding a couple cases in which
 
10
  they can appear. Not foolproof, but it does adapt to what new GCCs are
 
11
  putting out (e.g. cpp (GCC) 4.4.2 20091222 (Red Hat 4.4.2-20)).
 
12
 
 
13
Origin: backport, http://git.savannah.gnu.org/gitweb/?p=guile.git;a=commitdiff;h=445f31fc06d338f0cafda188d0287f935c2edc3c
 
14
 
 
15
Index: b/scripts/snarf-check-and-output-texi
 
16
===================================================================
 
17
--- a/scripts/snarf-check-and-output-texi
 
18
+++ b/scripts/snarf-check-and-output-texi
 
19
@@ -267,6 +267,17 @@
 
20
       (set! *file* file)
 
21
       (set! *line* line))
 
22
 
 
23
+     ;; newer gccs like to throw around more location markers into the
 
24
+     ;; preprocessed source; these (hash . hash) bits are what they translate to
 
25
+     ;; in snarfy terms.
 
26
+     (('location ('string . file) ('int . line) ('hash . 'hash))
 
27
+      (set! *file* file)
 
28
+      (set! *line* line))
 
29
+
 
30
+     (('location ('hash . 'hash) ('string . file) ('int . line) ('hash . 'hash))
 
31
+      (set! *file* file)
 
32
+      (set! *line* line))
 
33
+
 
34
      (('arglist rest ...)
 
35
       (set! *args* (do-arglist rest)))
 
36