Commit Graph

67 Commits

Author SHA1 Message Date
Bruce Korb da6d3adf1e test_text cleanups
From-SVN: r34020
2000-05-19 14:15:24 +00:00
Kaveh R. Ghazi 7021bb50d4 inclhack.def (broken_cabs): Update fix to handle comments following the cabs decl which terminate on the...
* fixinc/inclhack.def (broken_cabs): Update fix to handle comments
	following the cabs decl which terminate on the following line.
	Add the corresponding test_text case.

From-SVN: r33983
2000-05-18 15:47:31 +00:00
Bruce Korb 2dc693ee94 Keep HP-UX 11 from stomping on C++ math namespace
From-SVN: r33957
2000-05-17 14:59:20 +00:00
Bruce Korb 79589c4d8b added several "test_text" attributes; changed several fixes to use `c_fix = format'
and  re-alphabetized the fixes

From-SVN: r33930
2000-05-16 14:01:34 +00:00
Bruce Korb 99d05d9955 Add several tests and use the ``c_fix = format'' fixer more
From-SVN: r33895
2000-05-14 21:20:33 +00:00
Bruce Korb ba8fcfc31e implement "wrap" c_fix
From-SVN: r33892
2000-05-14 19:29:02 +00:00
Bruce Korb 88acf85484 fix up some of the testing
From-SVN: r33886
2000-05-12 21:59:39 +00:00
Zack Weinberg 4c6d912f7f enhance the format style c_fix & remove unneeded wrapper funcs
From-SVN: r33872
2000-05-12 15:51:55 +00:00
Robert Lipe f4305c31e5 inclhack.def (hpux8_bogus_inlines): Delete bypass for SCO.
* fixinc/inclhack.def (hpux8_bogus_inlines): Delete bypass for SCO.
        * fixincl.x: Regenerate.

From-SVN: r33865
2000-05-11 21:41:36 +00:00
Bruce Korb f5b105ca62 regenerated
From-SVN: r33844
2000-05-11 13:43:30 +00:00
Bruce Korb 87b6d63a2a disable hpux8_bogus_inlines on SCO
From-SVN: r33806
2000-05-09 21:16:48 +00:00
Bruce Korb 72b9c7fb37 Remove `extern double cabs' declarations from math.h
From-SVN: r33667
2000-05-04 14:50:14 +00:00
Bruce Korb 4c1880265e Added definitions needed by OSR5
From-SVN: r33556
2000-04-30 23:30:15 +00:00
Zack Weinberg bfab56e7ab cppinit.c (cpp_start_read): Turn off -Wtraditional if processing C++.
* cppinit.c (cpp_start_read): Turn off -Wtraditional if
	processing C++.
	* cpplib.c (_cpp_handle_directive): Improve warnings for
	traditional C and indented directives.

	* enquire.c, gsyslimits.h, limity.h, config/convex/fixinc.convex,
	fixinc/fixinc.irix, fixinc/fixinc.sco, fixinc/fixinc.wrap,
	fixinc/inclhack.def: Indent the # of #include_next one space.
	* cp/rtti.c: Un-indent #if and #endif.

	* cppexp.c (_cpp_parse_expr): If lex returns '#', it's a
	syntax error, but an error has already been printed.
	* cpplex.c (_cpp_parse_assertion): Give a more specific error
	message when called with nothing remaining on the line.
	(_cpp_lex_token): If _cpp_parse_assertion fails, return an
	OTHER token, not an ASSERTION.
	* cpplib.c (do_assert): When we create a 'base' node, clear
	its aschain pointer.

	* gcc.c-torture/compile/981211-1.c: Move to...
	* gcc.dg/cpp-as1.c: ...here.
	* gcc.dg/cpp-as2.c: New file.

	* gcc.dg/cpp-tradwarn1.c: Change warning regexps to match the
	compiler.

From-SVN: r32870
2000-04-02 22:50:55 +00:00
Bruce Korb 42a2c30e1b the undefine_null bypass pattern needs to match for DOS headers
From-SVN: r32199
2000-02-26 23:16:59 +00:00
Bruce Korb b6412bae50 regenerate
From-SVN: r32081
2000-02-20 23:15:50 +00:00
Zack Weinberg 78a0d70cdf frame.c (find_fde): Convert for loop to do-while so compiler sees it's always executed at least once.
* frame.c (find_fde): Convert for loop to do-while so compiler
	sees it's always executed at least once.
	* libgcc2.c (BBINBUFSIZE): Kill.
	(__bb_init_prg): Use fgets.
	(__bb_exit_trace_func): Don't paste strings.
	* unroll.c (unroll_loop): Initialize unroll_type, not
	unroll_number, and tweak logic to match.

	* i386.c (ix86_expand_int_movcc): Add explicit 'return 0' in
	all failure paths.
	(ix86_flags_dependant): Likewise.  Disentangle control flow.
	(ix86_sched_reorder): Break guts out to
	ix86_sched_reorder_pentium and ix86_sched_reorder_ppro.
	(ix86_sched_reorder_ppro): Initialize pair2 and insnp before
	any possible use.

	* i386.h (MACHINE_STATE_SAVE, MACHINE_STATE_RESTORE): Don't
	use string concatenation.  Don't save and restore esi.

	* fixinc/Makefile.in (fixincl.sh): Don't depend on inclhack.def.
	(machname.h): Remove script to separate file.  Use two-step
	sequence so target is not created if script fails.
	* fixinc/gen-machname.h: New file.  Handle case where no non-reserved
	identifiers are defined.
	* fixinc/fixlib.c (mn_get_regexps): Return a flag: if MN_NAME_PAT is
	an empty string, machine_name doesn't need to do anything at
	all.
	(is_cxx_header): Add more cases to regexp.
	* fixinc/fixlib.h: Update prototype.
	* fixinc/fixtests.c, fixinc/fixfixes.c: Update callers of
	mn_get_regexps.
	* fixinc/fixincl.c: Define NO_BOGOSITY.

	* fixinc/inclhack.def (no_double_slash, else_endif_label): Ifdef out.
	(hp_sysfile): Add missing comma.
	(math_exception): Put the wrapper ifdefs at the beginning and
	the end of the file.
	* fixinc/fixincl.x, fixinc/inclhack.sh: Regenerate.

From-SVN: r31744
2000-02-01 23:51:38 +00:00
Zack Weinberg 3be1fb7253 inclhack.def: Fixes to play nicer with FreeBSD, and corrections to comments.
2000-01-25  Zack Weinberg  <zack@wolery.cumb.org>

	* inclhack.def: Fixes to play nicer with FreeBSD, and
	corrections to comments.
	(cxx_unready): Add select expression.
	(irix_sockaddr): Add bypass expression.
	(machine_ansi_h_va_list): New fix.
	(stdio_va_list): No need to edit _BSD_VA_LIST_.
	Split out addition of "#include <stdarg.h>" to...
	(stdio_stdarg_h): ... here.
	(systypes_for_aix): Rename to systypes_stdlib_size_t.  Apply
	to stdlib.h also.  Do not munge _BSD_SIZE_T_.
	(sysz_stdlib_for_sun): Delete duplicate fix for unprotected
	size_t.
	(ultrix_ifdef): Tighten up select expression.

	* fixincl.tpl: Exorcise 'exesel'.  Rewrite calculations of
	re_ct and max_mach to avoid use of shell.  Make printed names
	match names in inclhack.def.  Use static copyright date.
	Don't count c_test and test expressions as requiring regex_t
	slots.  Add some commentary.
	* inclhack.tpl: Do not include the 'This script contains N
	fixup scripts' line if PROGRAM is defined.  Use static
	copyright date.

From-SVN: r31604
2000-01-25 08:06:23 +00:00
Zack Weinberg 52c207e293 Makefile.in (fixinc.sh): Depend on specs.
* Makefile.in (fixinc.sh): Depend on specs.
        * fixinc/Makefile.in: Add rule to create machname.h.
        (fixlib.o): Depend on machname.h.
        * fixinc/fixtests.c (machine_name): New test.
        * fixinc/fixfixes.c (machine_name): New fix.
        * fixinc/fixlib.c (mn_get_regexps): New helper function for
        the machine_name test and fix.
        * fixinc/fixlib.h: Prototype it.
        * fixinc/inclhack.def (machine_name): Use the C test and fix.
	* fixinc/fixincl.x, fixinc/inclhack.sh: Rebuild.

        * gcc.c (do_spec_1) [case P]: Take care not to create
        identifiers with three leading or trailing underscores.

	* fixinc/Makefile.in (FIXINC_DEFS): Add -DIN_GCC.
	(fixincl): Don't specify libraries twice on link line.
	(gnu-regex.o): Remove special rule.
	* fixinc/gnu-regex.c: Define REGEX_MALLOC if C_ALLOCA was
	defined by config.h.  Do not define _REGEX_RE_COMP.
	(regcomp): Allocate and initialize a fastmap.
	* fixinc/gnu-regex.h: Do not define _REGEX_RE_COMP.

From-SVN: r31542
2000-01-20 18:25:12 +00:00
Zack Weinberg 5c0d5b94d1 Makefile.in: Correct dependencies of fixincl and fixincl.o.
* fixinc/Makefile.in: Correct dependencies of fixincl and fixincl.o.
	* fixinc/fixfixes.c (IO_use, CTRL_use, IO_defn, CTRL_defn): New fixes.
	(fix_char_macro_defines, fix_char_macro_uses): New functions.

	* fixinc/fixlib.c (is_cxx_header): Do the text scan with a regexp.
	Recognize Emacs mode markers also.
	* fixinc/fixtests.c (else_endif_label): Fix bug in recognition of
	C++ comments in C++ headers.  Call is_cxx_header only if
	necessary.

	* fixinc/inclhack.def (avoid_bool): Add select for the problem and
	bypass for ncurses.
	(bsd43_io_macros, io_def_quotes, ioctl_fix_ctrl): Replace with...
	(io_def_quotes, io_use_quotes, ctrl_def_quotes, ctrl_use_quotes):
	... these, which use the new C fixes.
	(math_exception): Escape literal '+' in bypass expression.

	* fixinc/fixincl.x, fixinc/fixincl.sh, fixinc/inclhack.sh:
	Regenerate.

From-SVN: r31512
2000-01-19 21:41:04 +00:00
Zack Weinberg b51207a4d2 fixlib.c: Add copyright notice.
* fixinc/fixlib.c: Add copyright notice.
	(compile_re): New function.
	* fixinc/fixlib.h: Prototype compile_re.

	* fixinc/fixfixes.c, fixinc/fixtests.c, fixinc/fixincl.c:
	Use compile_re to compile regular expressions.

	* fixinc/fixincl.c (egrep_test): Don't bother asking regexec
	where the pattern matched.

	* fixinc/inclhack.def (sun_memcpy): Move to AAB_sun_memcpy,
	use 'replace'.
	(ultrix_ansi_compat): Likewise.
	(interactv_add1): Rename to 'isc_omits_with_stdc', remove shell test,
	add egrep test.
	(interactv_add2, interactv_add3): Delete.
	(x11_sprintf): Don't use filename glob.
	* fixinc/fixincl.x, fixinc/inclhack.sh, fixinc/fixincl.sh:
	Regenerate.

From-SVN: r31474
2000-01-17 21:45:29 +00:00
Bruce Korb 87ad679bfb C++ file type checking
From-SVN: r31125
1999-12-29 22:59:16 +00:00
Zack Weinberg d7eb5a45e2 fixtests.c (is_cxx_header): New fn, split out of double_slash_test.
1999-12-17 13:21 -0800  Zack Weinberg  <zack@rabi.columbia.edu>

	* fixtests.c (is_cxx_header): New fn, split out of
	double_slash_test.
	(else_endif_label): Allow "#endif // comment" in C++ headers,
	as determined by is_cxx_header.
	* fixfixes.c (else_endif_label_fix): Update comment.
	* fixincl.c: Don't output VERB_PROGRESS lines if stdout is not
	a tty.
	* genfixes: Correct double thinko in commandline parsing.
	* hackshell.tpl: Generate correct sh syntax for bypass
	entries.

	* inclhack.def (all): Whenever an inserted preprocessor
	conditional is split over multiple lines, use double
	backslashes in this file so the fixed header will be readable.

	(AAB_fd_zero_glibc_1_0): Rename to AAB_fd_zero_asm_posix_types_h
	and add bypass entry for correct version of this header.
	(AAB_fd_zero_glibc_1_x): Rename to AAB_fd_zero_gnu_types_h.
	(AAB_fd_zero_glibc_2_0): Rename to AAB_fd_zero_selectbits_h.

	(hpux8_bogus_inlines): New fix, split from...
	(ultrix_atof_param) ... here.
	(math_expression): Add bypass entry keyed to glibc comment
	indicating the problem has been dealt with; disable
	unnecessary sed operations; update commentary.
	(math_gcc_ifndefs): Rename to math_huge_val_from_dbl_max,
	add select and bypass entries, simplify shell operation.
	(math_huge_val_ifndef): Split from math_gcc_ifndefs.

	(ip_missing_semi, rs6000_param, tinfo_cplusplus,
	 ultrix_atof_param): Add select entry.
	(stdio_va_list, sunos_mather_decl): Add bypass entry.
	(systypes_for_aix, sysv86_string, tinfo_cplusplus): Put the
	comments with the fixes they describe.

	* fixincl.x, fixincl.sh, inclhack.sh: Regen.

From-SVN: r30999
1999-12-17 21:49:30 +00:00
Bruce Korb c5984b7b9e don't skip GLIBC files any more, more C++ header testing, corrected spelling of mach
From-SVN: r30704
1999-11-29 14:35:50 +00:00
Bruce Korb 8aeb3b0e4c __FD_ZERO fixes for gnu libc1&2
From-SVN: r30613
1999-11-22 15:05:48 +00:00
Robert Lipe 86765ca02c SVR5 Byteorder fixes
Co-Authored-By: Bruce Korb <autogen@linuxbox.com>

From-SVN: r30538
1999-11-15 14:47:53 +00:00
Bruce Korb 8f9ca91274 Use C-coded tests and fixes for #endif/#else labels
From-SVN: r30130
1999-10-22 13:23:43 +00:00
Loren J. Rittle 70d42369b1 inclhack.def: Restore patch lost during last merge of "no_bogosity" branch.
* fixinc/inclhack.def: Restore patch lost during last merge of
        "no_bogosity" branch.
        * fixinc/inclhack.sh, fixinc/fixincl.x: Rebuilt.

From-SVN: r30005
1999-10-15 00:02:01 -06:00
Gavin Romig-Koch abf7cec73a fixincludes: Add a HPUX 11 fix for inttypes.h.
* fixincludes: Add a HPUX 11 fix for inttypes.h.
        * fixinc/inclhack.def: Same.
        * fixinc/inclhack.sh, fixinc/fixincl.sh, fixinc/fixincl.x: Regenerate.

From-SVN: r30004
1999-10-15 00:00:29 -06:00
Bruce Korb 5abc1f741e Merge from no_bogosity
From-SVN: r29918
1999-10-12 14:44:18 +00:00
Loren J. Rittle c78896f083 Do not trash single-line C-style comments
From-SVN: r28735
1999-08-17 18:32:32 +00:00
Bruce Korb 94cc603610 IRIX 5.2's <sys/asm.h> contains an asm comment with an apostrophe
From-SVN: r28589
1999-08-07 22:42:56 +00:00
Kaveh R. Ghazi c354f40df2 fixincludes: Fix the return type of bsearch, char* -> void*.
* fixincludes: Fix the return type of bsearch, char* -> void*.

        * fixinc/inclhack.def: Likewise.

From-SVN: r28440
1999-08-03 04:06:31 +00:00
Bruce Korb cd12e6b44a Double the backslash so sed gets a chance to see it.
From-SVN: r27953
1999-07-06 07:13:44 +00:00
David O'Brien eca5590fb8 inclhack.def (stdio_va_list): This patch Removes a semicolon from the BSD VA_LIST replacement expression.
* fixinc/inclhack.def(stdio_va_list): This patch Removes a
	semicolon from the BSD VA_LIST replacement expression.
	* fixinc/inclhack.sh: regen
	* fixinc/fixincl.x: regen
	* fixinc/mkfixinc.sh: Have `i[34567]86-*-freebsd*' machines
	now use the fixincl program.

From-SVN: r27811
1999-06-28 07:07:04 +00:00
Bruce Korb d71ef9d4a6 inclhack.def: Add fix development commentary
1999-06-23  Bruce Korb  <ddsinc09@ix.netcom.com>
	*fixinc/inclhack.def:  Add fix development commentary
	(read_ret_type): reactivate and add selection clause
	(zzz_*): tweak output file name to match what is used in hackshell.tpl
	*fixinc/{fixincl.x|inclhack.sh}: regen

From-SVN: r27718
1999-06-23 12:29:01 +00:00
Bruce Korb 15b183364a inclhack.def (end_else_label): combined else_label and endif_label and fixed the sed expression.
*fixinc/inclhack.def(end_else_label): combined else_label
	and endif_label and fixed the sed expression.
	*fixinc/{fixincl.x|inclhack.sh}: regen

From-SVN: r27703
1999-06-22 09:39:06 +00:00
Bruce Korb 51bf846ee9 Scripts must end with a new-line
From-SVN: r27596
1999-06-18 12:44:14 +00:00
Bruce Korb 180b3d507f ISCTRL fix and dgux patch
From-SVN: r27577
1999-06-17 15:11:17 +00:00
Jeffrey A Law 5cda1ab62a inclhack.def (endif_label): Add additional selector for more bogus stuff after #endif statements.
* fixinc/inclhack.def (endif_label): Add additional selector for
        more bogus stuff after #endif statements.
        * fixinc/inclhack.sh, fixinc/fixincl.x: Rebuilt.

From-SVN: r27486
1999-06-10 20:20:58 -06:00
Bruce Korb 9a726fc16f Corrected quote formation
From-SVN: r27471
1999-06-10 14:43:44 +00:00
Bruce Korb b4e01caa36 fix a selection expression, skip a bypass
From-SVN: r27468
1999-06-10 07:36:01 +00:00
Jeffrey A Law 88b94e29f0 inclhack.def (no_double_slash): Fix quoting for test.
* fixinc/inclhack.def (no_double_slash): Fix quoting for test.
        * fixinc/inclhack.sh, fixinc/fixincl.x, fixinc/fixincl.sh; Rebuilt.

From-SVN: r27460
1999-06-09 16:17:49 -06:00
Bruce Korb 07412b0710 Regenerate
From-SVN: r27448
1999-06-09 07:02:39 +00:00
Kaveh R. Ghazi b75b4e92c8 inclhack.def (sun_catmacro): Escape parens in the select pattern.
1999-06-09  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
        * fixinc/inclhack.def (sun_catmacro): Escape parens in the select
        pattern.
        * fixinc/fixincl.x, fixinc/inclhack.sh: Rebuilt.

From-SVN: r27434
1999-06-08 20:52:16 -06:00
Jeff Law c0a77c9272 inclhack.def (bad_lval): Remove bogus selector.
* fixinc/inclhack.def (bad_lval): Remove bogus selector.
        * fixinc/inclhack.sh, fixinc/fixincl.x, fixinc/fixincl.sh; Rebuilt.

From-SVN: r27423
1999-06-07 19:53:49 -06:00
Jeffrey A Law fbc35bc121 inclhack.def (avoid_bool): Also catch "typedef [unsigned] int bool".
* fixinc/inclhack.def (avoid_bool): Also catch
        "typedef [unsigned] int bool".
        * fixinc/inclhack.sh, fixinc/fixincl.x, fixinc/fixincl.sh: Rebuilt.

From-SVN: r27418
1999-06-07 18:10:51 -06:00
Kaveh R. Ghazi 5aa8e9796b inclhack.def (math_gcc_ifndefs): Insert whitespace between sed's -e flag, and the open-quote following it.
* fixinc/inclhack.def (math_gcc_ifndefs): Insert whitespace
        between sed's -e flag, and the open-quote following it.
        * fixinc/fixincl.x, fixinc/fixincl.sh: Rebuilt.

From-SVN: r27405
1999-06-07 14:35:14 -06:00
Jeff Law 149911d4ea inclhack.def (limits_ifndefs): Also apply to sys/limits.h
�
        * fixinc/inclhack.def (limits_ifndefs): Also apply to sys/limits.h
        * fixinc/fixincl.x: Regenerated.
        * fixinc/inclhack.sh: Regenerated.

From-SVN: r27338
1999-06-03 17:06:30 -06:00
Bruce Korb 5403593a44 Io_Def_Quotes): corrected sed expression
From-SVN: r27327
1999-06-03 07:56:01 +00:00