diff options
| author | neil <neil@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-11-08 20:15:05 +0000 |
|---|---|---|
| committer | neil <neil@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-11-08 20:15:05 +0000 |
| commit | 50c1b6038d1a7a5ad0c0cfde7dbc3d7dfa80978b (patch) | |
| tree | 7ced8c4b49f8690bf788ef65eacd2b9e2a2978df | |
| parent | d7c5dd0443b9dafa7d8dfc5f13ef77b2301c0214 (diff) | |
| download | ppe42-gcc-50c1b6038d1a7a5ad0c0cfde7dbc3d7dfa80978b.tar.gz ppe42-gcc-50c1b6038d1a7a5ad0c0cfde7dbc3d7dfa80978b.zip | |
* cppmain.c (cpp_preprocess_file): Loop to pop any -included
buffers.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58933 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 5 | ||||
| -rw-r--r-- | gcc/cppmain.c | 7 |
2 files changed, 11 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index dda45b26f9e..b473c789acb 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2002-11-08 Neil Booth <neil@daikokuya.co.uk> + + * cppmain.c (cpp_preprocess_file): Loop to pop any -included + buffers. + 2002-11-08 Kazu Hirata <kazu@cs.umass.edu> * config/h8300/h8300.md (two anonymous test insns): New. diff --git a/gcc/cppmain.c b/gcc/cppmain.c index 4036bc3b537..9d8d42c2009 100644 --- a/gcc/cppmain.c +++ b/gcc/cppmain.c @@ -78,7 +78,12 @@ cpp_preprocess_file (pfile, in_fname, out_stream) /* A successful cpp_read_main_file guarantees that we can call cpp_scan_nooutput or cpp_get_token next. */ if (options->no_output) - cpp_scan_nooutput (pfile); + { + /* Scan -included buffers, then the main file. */ + while (pfile->buffer->prev) + cpp_scan_nooutput (pfile); + cpp_scan_nooutput (pfile); + } else if (options->traditional) scan_translation_unit_trad (pfile); else |

