Commit Graph

124 Commits

Author SHA1 Message Date
Ian Lance Taylor
0016a02db3 Include source file name in dependency output.
From-SVN: r7214
1994-05-05 16:28:46 +00:00
Jason Merrill
767d412ca1 (special_symbol): Don't copy simple strings, use wchar_type.
(main): Setup wchar_type for C++ if needed.
        (initialize_builtins): Use wchar_type.

From-SVN: r7212
1994-05-04 21:32:22 +00:00
Jim Wilson
3375e6626a (macroexpand): Use start_line for line number of the new
instack level pushed at the end.

From-SVN: r7174
1994-04-28 16:03:41 -07:00
Richard Kenner
9b03496193 (do_error): Don't terminate.
From-SVN: r7080
1994-04-19 19:00:10 -04:00
Jason Merrill
acf7262cb8 cccp.c: Don't implicitly wrap LOCAL_INCLUDE_DIR.
* cccp.c: Don't implicitly wrap LOCAL_INCLUDE_DIR.
        (struct default_include): Add cxx_aware field.
        (include_defaults_array): Ditto.
        (main): Use cxx_aware field.

From-SVN: r7041
1994-04-12 23:42:36 +00:00
Jim Wilson
80512db770 (rescan): Don't look for C++ // comment before directive.
Handle \-newline inside a C++ // comment.
(skip_if_group): Likewise.
(handle_directive): Also handle C++ // comment after #.  Point
ip->bufp after the comment start before calling
skip_to_end_of_comment.
(validate_else): Handle \-newline inside a C++ // comment.
(skip_to_end_of_comment, macarg1, discard_comments): Likewise.

From-SVN: r7028
1994-04-11 10:27:17 -07:00
Jim Wilson
18e2b1c06e (discard_comments): Replace comments with a single space.
From-SVN: r6993
1994-04-06 16:01:45 -07:00
Jason Merrill
f98e603e09 cccp.c (special_symbol, [...]): Output "__wchar_t" for C++.
* cccp.c (special_symbol, case T_WCHAR_TYPE): Output "__wchar_t"
        for C++.

From-SVN: r6959
1994-04-04 21:21:02 +00:00
Jim Wilson
39d05dae1b (pcfinclude): Modify comment referring to gstddef.h.
From-SVN: r6949
1994-03-31 21:52:18 -08:00
Richard Kenner
253245dfd1 (for_lint): Variable renamed from `lint'.
From-SVN: r6904
1994-03-25 18:16:01 -05:00
Jim Wilson
b0866c745a (before_system, last_before_system): New variables.
(main): Handle -isystem option.  Insert -isystem directories in
search chain at first_system_include.

From-SVN: r6812
1994-03-18 12:35:42 -08:00
Richard Kenner
fe701b404f (do_include, hack-vms_include_specification): Change handling of
'#include filename' to be compatible with VAX-C.

From-SVN: r6756
1994-03-12 07:37:03 -05:00
Richard Kenner
53e52f00a4 (main, finclude, check_precompiled): When safe_read returns a partial buffer, this means EOF has been reached...
(main, finclude, check_precompiled): When safe_read returns a partial
buffer, this means EOF has been reached; don't try to read any more.

From-SVN: r6738
1994-03-10 15:02:45 -05:00
Richard Kenner
42e2194b02 (no_record_file): New variable.
(main): Set it for -imacros and -include files.
(do_endif): Don't call record_control_macro for -include or -imacros files or
files included from -imacros.

From-SVN: r6708
1994-03-07 13:26:52 -05:00
Richard Kenner
7633af9506 (check_precompiled): Delete unused var dollar_loc.
(pcstring_used): Delete unused var TMP.
(write_output): Delete unused var WRITTEN.
(assertion_lookup): Delete unused var BP.
(pedwarn_with_file_and_line): Delete unused var I.

From-SVN: r6675
1994-02-28 08:11:38 -05:00
Richard Kenner
2af5e9e20d (main, args case 'D'): Rewrite to avoid uninitialized var.
(main, args case 'A'): Delete unused var P1.
(rescan): Initialize STR.
(do_xifdef, do_endif): Initialize arg to skip_to_end_of_comment.

From-SVN: r6641
1994-02-27 10:46:21 -05:00
Jim Wilson
6e7f952e96 (read_name_map, read_filename_string, open_include_file):
New functions.
(struct file_name_list): New members: name_map, got_name_map.
(main, path_include, do_include, do_once): Set got_name_map.
(do_include): Use open_include_file instead of open.  Add new
parameter to lookup_import calls.
(lookup_import): New parameter searchptr.  Call open_include_file
instead of open.

From-SVN: r6307
1993-12-24 12:49:47 -08:00
Jim Wilson
3c0e5268f9 (main): Cast alloca result to char * to avoid warning.
From-SVN: r6268
1993-12-22 11:25:04 -08:00
Richard Kenner
a0c2b8e969 (main): Strip off ".cpp" extension.
From-SVN: r6261
1993-12-22 07:45:11 -05:00
Richard Kenner
389bb5081b (main): Combine tests of single-character suffixes.
(deps_output): Different second parameter: SPACER determines meaning of first
argument (target, dependency, literal text).
Wrap output correctly.

From-SVN: r6224
1993-12-12 08:19:22 -05:00
Richard Kenner
9b1674a8ed (INPUT_STACK_MAX): Double size.
From-SVN: r6208
1993-12-11 08:50:06 -05:00
Richard Stallman
0031ac5789 (output_line_command): Handle NO_IMPLICIT_EXTERN_C here.
(main): Not here.

From-SVN: r6038
1993-11-08 07:56:19 +00:00
Richard Stallman
c9a8a295f8 (safe_read, safe_write): Handle EINTR.
From-SVN: r6015
1993-11-05 21:43:08 +00:00
Richard Stallman
f0fbff1f65 (main): Handle NO_IMPLICIT_EXTERN_C.
From-SVN: r6009
1993-11-05 11:12:43 +00:00
Richard Stallman
bb7de82295 (safe_read): New function.
(main, finclude, check_precompiled): Use safe_read.

From-SVN: r5982
1993-11-03 20:09:56 +00:00
Richard Stallman
9022605c7e (safe_write): New function.
(write_output): Use safe_write.

From-SVN: r5960
1993-11-01 07:07:46 +00:00
Richard Stallman
a3fb124a50 (do_ident): Substitute macros and output here.
(directive_table): Turn off the pass_thru field for #ident.

From-SVN: r5959
1993-11-01 06:38:43 +00:00
Jim Wilson
5d672cd7e6 (sys_errlist): Conditionalize declaration for BSD 4.4.
From-SVN: r5843
1993-10-20 16:20:09 -07:00
Richard Kenner
0e57600536 (main): Don't catch SIGPIPE if no such signal.
From-SVN: r5782
1993-10-13 17:55:46 -04:00
Richard Stallman
65715deac9 (output_line_command): Output the `4' flag only if cplusplus.
(do_line): Handle the `4' flag.

From-SVN: r5781
1993-10-13 21:52:31 +00:00
Richard Stallman
4514982879 (main): New option -lang-c-c++-comments.
From-SVN: r5666
1993-10-07 21:39:38 +00:00
Richard Stallman
d2a228624e (struct file_name_list): Add new field c_system_include_path.
(*various*): Set this flag correctly
(is_system_include): Return 2 if C-language system include.
(output_line_command): Output " 4" after " 3" for C-language system
include.

From-SVN: r5659
1993-10-07 18:48:55 +00:00
Richard Kenner
9e92edb4fb (rescan): Don't expand an identifier after a '#'.
From-SVN: r5611
1993-10-05 16:04:55 -04:00
Paul Eggert
f7531123b5 (quote_string): New function.
(special_symbol, write_output, output_line_command): Use it to quote
special characters in file names on output.
(do_line): Parse escape sequences in #line directives' file names.

From-SVN: r5529
1993-09-29 05:42:10 +00:00
Paul Eggert
bb2f42b1ca (quote_string): New function.
(special_symbol): Use it to properly quote special chars in __FILE__.

From-SVN: r5526
1993-09-29 01:29:31 +00:00
Richard Stallman
334eb14298 (output_dots): New function.
(do_include): Call it (to indent output for print_include_names).

From-SVN: r5512
1993-09-28 22:51:54 +00:00
Ian Lance Taylor
9e7270cda3 If NO_BUILTIN_SIZE_TYPE defined, don't refer to SIZE_TYPE.
Likewise for PTRDIFF_TYPE

From-SVN: r5490
1993-09-27 23:01:26 +00:00
Richard Kenner
78af79ab5a (skip_if_group): Check for traditional mode when skipping ahead to
next #, ignore unless at beginning of line.

From-SVN: r5257
1993-09-03 18:03:32 -04:00
Richard Stallman
e6157ab48f (main): If -v, print header search dir list.
From-SVN: r5087
1993-08-06 08:24:14 +00:00
Richard Stallman
d19184d67a (main): For -iwithprefix, if no include_prefix,
make a default from GCC_INCLUDE_DIR.
Support -iwithprefixbefore.

From-SVN: r4793
1993-06-29 04:37:51 +00:00
Brendan Kehoe
6b46c09032 toplev.c (report_error_function): Change format of the included-file stack to be more readable.
* toplev.c (report_error_function): Change format of the
	included-file stack to be more readable.
	* cccp.c (print_containing_files): Likewise.

From-SVN: r4710
1993-06-22 13:56:40 -04:00
Richard Stallman
ceaff0a861 (default_include): Put TOOL_INCLUDE_DIR after
LOCAL_INCLUDE_DIR in non-cross case.

From-SVN: r4534
1993-05-21 23:14:00 +00:00
Richard Stallman
148597b92e (macroexpand): Treat `foo ( )' as 0 args if foo wants 0 args.
From-SVN: r4323
1993-05-04 16:43:42 +00:00
Richard Stallman
b126e7cecc Comment fix.
From-SVN: r4282
1993-04-30 03:15:53 +00:00
Richard Stallman
5f12e361fa (no_precomp): Make it 1 by default.
From-SVN: r4057
1993-04-09 21:42:29 +00:00
Jim Wilson
a94d16c611 (do_include): For missing header file...
(do_include): For missing header file, if -M, don't
output dependencies, and warning not error if no dependency is
needed.

From-SVN: r4033
1993-04-06 12:32:37 -07:00
Richard Stallman
50f151047d (do_include): For "..." case, leave fend pointing at terminating 0.
Distinct error msgs for empty file name and for bad syntax.

From-SVN: r3880
1993-03-25 21:51:47 +00:00
Richard Stallman
2fc3335291 (collect_expansion): Don't make # special in argless macro.
From-SVN: r3818
1993-03-22 02:03:01 +00:00
Richard Stallman
ad0c9fa199 Follow whitespace conventions near parens.
From-SVN: r3756
1993-03-16 06:07:43 +00:00
Richard Stallman
c6469b460a (main): Report errors in output to pcp_outfile.
(write_output): Use pfatal_with_name for errors.

From-SVN: r3755
1993-03-16 06:04:33 +00:00