aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-ppoutput.c
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.co.uk>2003-04-21 19:21:59 +0000
committerNeil Booth <neil@gcc.gnu.org>2003-04-21 19:21:59 +0000
commit74eb4b3e2ef09909768f6b7ce18b0b6c03f26f5b (patch)
tree18ec4d7a6b4b870f1e5aa394f9a86c0a58ffc185 /gcc/c-ppoutput.c
parent65085aa3eff4cbaf515a4fcbb16d2692ecb1ab74 (diff)
downloadgcc-74eb4b3e2ef09909768f6b7ce18b0b6c03f26f5b.zip
gcc-74eb4b3e2ef09909768f6b7ce18b0b6c03f26f5b.tar.gz
gcc-74eb4b3e2ef09909768f6b7ce18b0b6c03f26f5b.tar.bz2
c-ppoutput.c (cb_include): Don't take a cpp_token.
* c-ppoutput.c (cb_include): Don't take a cpp_token. * cppfiles.c: Don't undef strcmp. (find_include_file): Don't take a cpp_token. Check for empty file names. (_cpp_execute_include, _cpp_compare_file_date): Don't take a cpp_token. (cpp_push_include): Simplify. * cpphash.h (_cpp_execute_include, _cpp_compare_file_date): Update. * cpplib.c (glue_header_name): Return the file name, not a cpp_token. (parse_include): Similary. Don't check for zero-length filenames. (do_include_common, do_pragma_dependency): Update accordingly. * cpplib.h (struct cpp_callbacks): Change prototype of include. From-SVN: r65894
Diffstat (limited to 'gcc/c-ppoutput.c')
-rw-r--r--gcc/c-ppoutput.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/gcc/c-ppoutput.c b/gcc/c-ppoutput.c
index 69eec22..2c1835d 100644
--- a/gcc/c-ppoutput.c
+++ b/gcc/c-ppoutput.c
@@ -55,7 +55,7 @@ static void cb_line_change PARAMS ((cpp_reader *, const cpp_token *, int));
static void cb_define PARAMS ((cpp_reader *, unsigned int, cpp_hashnode *));
static void cb_undef PARAMS ((cpp_reader *, unsigned int, cpp_hashnode *));
static void cb_include PARAMS ((cpp_reader *, unsigned int,
- const unsigned char *, const cpp_token *));
+ const unsigned char *, const char *, int));
static void cb_ident PARAMS ((cpp_reader *, unsigned int,
const cpp_string *));
static void cb_def_pragma PARAMS ((cpp_reader *, unsigned int));
@@ -345,15 +345,18 @@ cb_undef (pfile, line, node)
}
static void
-cb_include (pfile, line, dir, header)
- cpp_reader *pfile;
+cb_include (pfile, line, dir, header, angle_brackets)
+ cpp_reader *pfile ATTRIBUTE_UNUSED;
unsigned int line;
const unsigned char *dir;
- const cpp_token *header;
+ const char *header;
+ int angle_brackets;
{
maybe_print_line (print.map, line);
- fprintf (print.outf, "#%s %s\n", dir,
- cpp_token_as_text (pfile, header));
+ if (angle_brackets)
+ fprintf (print.outf, "#%s <%s>\n", dir, header);
+ else
+ fprintf (print.outf, "#%s \"%s\"\n", dir, header);
print.line++;
}