Commit Graph

1413 Commits

Author SHA1 Message Date
Paul Eggert
1fe611e544 Attempt to fix SunOS 4.1.4 porting bug reported by Peter Klein in
<http://mail.gnu.org/pipermail/bug-bison/2002-October/001674.html>.
2002-10-13 06:00:24 +00:00
Paul Eggert
a6352deb14 (BISON_PREREQ_TIMEVAR): Check for <sys/time.h>.
Include <sys/time.h> when checking for clock_t and struct tms.
Use same include order as source.
2002-10-13 05:59:40 +00:00
Paul Eggert
bd0ba42d72 Import GCC version as of today, then merge Bison's changes.
Change "GCC" to "Bison" in copyright notice.
2002-10-13 05:58:38 +00:00
Paul Eggert
46b8b6ce90 Fix copyright and authorship notice to point to Bison, not GCC. 2002-10-13 05:57:10 +00:00
Paul Eggert
fdabfd76d6 [! IN_GCC && HAVE_SYS_TIME_H]: Include <sys/time.h>.
Update copyright date and clarify comments.
(get_time) [IN_GCC]: Keep the GCC version for reference.

Merge GCC changes.  Change "GCC" to "Bison" in the copyright notice.
2002-10-13 05:56:20 +00:00
Paul Eggert
ea9ed226e0 Import of GCC head 2002-10-11 2002-10-13 04:42:59 +00:00
Paul Eggert
98194095fe * src/reader.c (grammar_current_rule_check):
Don't worry about the default action if $$ is untyped.
Prevents bogus warnings reported by Jim Gifford in
<http://mail.gnu.org/pipermail/bug-bison/2002-October/001673.html>.
2002-10-13 03:53:18 +00:00
Paul Eggert
3f4c0f8017 (grammar_current_rule_check):
Don't worry about the default action if $$ is untyped.
Prevents bogus warnings reported by Jim Gifford in
<http://mail.gnu.org/pipermail/bug-bison/2002-October/001673.html>.
2002-10-13 03:52:53 +00:00
Paul Eggert
14904b8965 * data/c.m4 (b4_token_enum): Do not define YYTOKENTYPE.
* data/glr.c, data/lalr1.cc, data/yacc.c:
Output token definitions before the first part of user declarations.
Fixes compatibility problem reported by Jim Gifford for kbd in
<http://mail.gnu.org/pipermail/bug-bison/2002-October/001672.html>.
2002-10-12 23:21:00 +00:00
Paul Eggert
17acead581 Output token definitions before the first part of user declarations. 2002-10-12 23:20:23 +00:00
Paul Eggert
095b9f05c3 (b4_token_enum): Do not define YYTOKENTYPE. 2002-10-12 23:18:52 +00:00
Paul Eggert
68449b3ad3 (Calling Convention): Fix strncmp typo. 2002-10-11 21:19:27 +00:00
Paul Eggert
ff6dca1839 * data/yacc.c (yyreport_parse_error): Remove, putting its body into...
(yyparse): here.  This undoes some of the 2002-07-25 change.
Compatibility problem reported by Ralf S. Engelschall with
OSSP cfg <http://www.ossp.org/pkg/lib/cfg/>.
2002-10-11 20:54:17 +00:00
Paul Eggert
df5aed8c11 (yyreport_parse_error): Remove, putting its body into...
(yyparse): here.  This undoes some of the 2002-07-25 change.
Compatibility problem reported by Ralf S. Engelschall with
OSSP cfg <http://www.ossp.org/pkg/lib/cfg/>.
2002-10-11 20:53:39 +00:00
Akim Demaille
eb71459201 * tests/regression.at Characters Escapes): New.
* src/scan-gram.l (SC_ESCAPED_CHARACTER): Accept ' in strings and
characters.
Reported by Jan Nieuwenhuizen.
2002-10-11 11:23:19 +00:00
Akim Demaille
b7195100fd * po/id.po: New. 2002-10-11 10:14:32 +00:00
Paul Eggert
f28a0f2dd1 Portability fixes for bitsets; this also avoids several GCC warnings. 2002-10-10 07:38:40 +00:00
Paul Eggert
303e6da265 Include bitset.h, not bbitset.h. 2002-10-10 07:35:19 +00:00
Paul Eggert
ef5da92061 Include <stddef.h>, for offsetof.
(lbitset_bytes): Adjust to new, unique names for structures.

(lbitset_and, lbitset_and_cmp, lbitset_andn, lbitset_andn_cmp,
lbitset_or, lbitset_or_cmp, lbitset_xor, lbitset_xor_cmp,
lbitset_empty_p, lbitset_ones, lbitset_not, lbitset_subset_p,
lbitset_disjoint_p, debug_lbitset): Supply prototype decls.

(enum_lbitset_find_mode): New type.  All instances of parameters of
type enum FOO are now of type enum_FOO, to conform to the C Standard.

(struct lbitset_struct, lbitset, bitset_struct, PFV): Remove.

(lbitset_and, lbitset_andn, lbitset_or, lbitset_xor): New functions.
2002-10-10 07:33:59 +00:00
Paul Eggert
3e0a8627e1 (ebitset_bytes): Adjust to new, unique names for structures.
(enum_ebitset_find_mode): New type.
(struct ebitset_struct, ebitset, struct bitset_struct, PFV): Remove.
(ebitset_and, ebitset_andn, ebitset_or,
ebitset_xor, ebitset_copy, ebitset_ones, ebitset_empty_p): New decls.
2002-10-10 07:28:53 +00:00
Paul Eggert
fd5c1e824e enum -> enum_ 2002-10-10 07:26:15 +00:00
Paul Eggert
f5e211a120 (bitsetv_alloc): Return a size that is aligned properly for vectors of
objects.  Do not assume that adding a header size to a multiple of a
word size yields a value that is properly aligned for the whole union.

(bitsetv_alloc): Add a cast to (void *) to avoid a GCC warning.
2002-10-10 07:25:21 +00:00
Paul Eggert
55e728eb31 (bitset_stats_bytes): Adjust to new, unique names for structures.
(bitset_stats_count, bitset_stats_empty_p, bitset_stats_ones,
bitset_stats_zero, bitset_stats_copy, bitset_stats_disjoint_p,
bitset_stats_equal_p, bitset_stats_not, bitset_stats_subset_p,
bitset_stats_and, bitset_stats_and_cmp, bitset_stats_andn,
bitset_stats_andn_cmp, bitset_stats_or, bitset_stats_or_cmp,
bitset_stats_xor, bitset_stats_xor_cmp, bitset_stats_and_or,
bitset_stats_and_or_cmp, bitset_stats_andn_or,
bitset_stats_andn_or_cmp, bitset_stats_or_and,
bitset_stats_or_and_cmp): Supply prototype decls, to improve the
type-checking that GCC can do.

(struct bitset_stats_struct, bitset_stats, struct bitset_struct): Remove.
2002-10-10 07:23:15 +00:00
Paul Eggert
47c8386f83 (struct bitset_struct): Remove, replacing with....
(union bitset_union, struct abitset_struct, struct ebitset_struct,
struct lbitset_struct, struct bitset_stats_struct): New types.
All uses of struct bitset_struct changed to union bitset_union,
etc.
(bitset_next, bitset_prev, bitset_only_set_p): Declare.
2002-10-10 07:20:24 +00:00
Paul Eggert
d5c559cde4 (bitset_op4_cmp): Supply prototype decls,
to improve the type-checking that GCC can do.

(bitset_and_or_, bitset_andn_or_, bitset_or_and_): New functions.
2002-10-10 07:18:47 +00:00
Paul Eggert
d9d83ef277 (enum_bitset_ops, enum_bitset_type): New types.
All instances of parameters of type enum bitset_opts are now of
type enum_bitset_opts, to conform to the C Standard, and similarly
for enum_bitset_type.

(bitset): Now points to a union, not to a struct.
All instances of "struct bitset_struct *" replaced with "bitset".

(bitset_and_or_, bitset_andn_or_, bitset_or_and_): New decls.
2002-10-10 07:15:56 +00:00
Paul Eggert
d4d399fcce Include <stddef.h>, for offsetof.
(abitset_bytes): Return a size that is aligned
properly for vectors of objects.  Do not assume that adding a
header size to a multiple of a word size yields a value that is
properly aligned for the whole union.

(abitset_ones, abitset_zero, abitset_empty_p, abitset_copy1,
abitset_not, abitset_equal_p, abitset_subset_p, abitset_disjoint_p,
abitset_and, abitset_and_cmp, abitset_andn, abitset_andn_cmp,
abitset_or, abitset_or_cmp, abitset_xor, abitset_xor_cmp,
abitset_and_or, abitset_and_or_cmp, abitset_andn_or,
abitset_andn_or_cmp, abitset_or_and, abitset_or_and_cmp,
abitset_copy): Supply prototype decls, to improve the type-checking
that GCC can do.

(struct abitset_struct, abitset, struct bitset_struct): Remove.
2002-10-10 07:13:58 +00:00
Paul Eggert
6fbe49845f * lib/bitset.h (bitset_reset): Do not assume that bitset_word is
the same width as int.  This reapplies a hunk of the 2002-08-12 patch
<http://mail.gnu.org/pipermail/bison-patches/2002-August/001111.html>,
which was inadvertently undone by the 2002-09-30 patch.
* lib/lbitset.c (debug_lbitset): Do not assume that bitset_word is
the same width as int.
2002-10-07 19:58:00 +00:00
Paul Eggert
7933f2b5dd Bison should now work on 64-bit hosts. 2002-10-07 06:08:30 +00:00
Paul Eggert
0f9cd74fdb (bitset_reset): Do not assume that bitset_word is
the same width as int.  This reapplies a hunk of the 2002-08-12 patch
<http://mail.gnu.org/pipermail/bison-patches/2002-August/001111.html>,
which was inadvertently undone by the 2002-09-30 patch.
2002-10-07 05:43:35 +00:00
Paul Eggert
09147be095 (debug_lbitset): Do not assume that bitset_word is the same width as
int.
2002-10-07 05:41:35 +00:00
Paul Eggert
7a542f5d81 Bump to 1.50a. 2002-10-07 04:51:50 +00:00
Paul Eggert
420f93c83b Version 1.50. 2002-10-05 06:25:50 +00:00
Paul Eggert
a337a5eb7e (AC_INIT): Version 1.50. 2002-10-05 06:24:55 +00:00
Paul Eggert
595878d7f5 Update and regenerate. 2002-10-05 06:23:42 +00:00
Paul Eggert
242a6e484e (reader): SHRT_MAX -> SYMBOL_NUMBER_MAX. 2002-10-05 05:47:51 +00:00
Paul Eggert
01eb033cf5 (SYMBOL_NUMBER_MAX): New macro. 2002-10-05 05:47:14 +00:00
Paul Eggert
1c303b00fe (GOTO_NUMBER_MAX): INT_MAX -> SHRT_MAX. 2002-10-05 05:46:42 +00:00
Paul Eggert
f704e33362 (ITEM_NUMBER_MIN): MIN_MAX -> INT_MIN. 2002-10-05 05:46:08 +00:00
Paul Eggert
5beedd9b58 * lib/bbitset.h (BITSET_WINDEX_MAX): Redefine so that it cannot be
interpreted as signed.
* lib/ebitset.c (ebitset_list): Fix bug.
From Michael Hayes.
2002-10-05 05:02:30 +00:00
Paul Eggert
9abb46d527 (AM_CFLAGS): Renamed from CFLAGS.
(AM_YFLAGS): Renamed from YFLAGS.
2002-10-05 04:54:54 +00:00
Paul Eggert
cd931d9b53 (AM_CFLAGS): Renamed from CFLAGS. 2002-10-05 04:53:54 +00:00
Paul Eggert
a4bf0390a0 (Braces parsing): Use grep, not fgrep, as POSIX 1003.1-2001 has
removed fgrep.
2002-10-05 04:50:45 +00:00
Paul Eggert
72d2299ca0 Minor spelling, grammar, and white space fixes.
(Symbols): Mention that any negative value returned from yylex
signifies end-of-input.  Warn about negative chars.  Mention
the portable Standard C character set.
2002-10-05 04:45:45 +00:00
Paul Eggert
ff68026d4f More fixes for 64-bit hosts and large bitsets. 2002-10-02 08:03:54 +00:00
Paul Eggert
bf5c381136 (lbitset_bytes): Use size_t, not unsigned int, to count bytes. 2002-10-02 08:02:06 +00:00
Paul Eggert
5c319390d7 (lbitset_size, lbitset_list, lbitset_list_merge):
Use bitset_bindex, not int or unsigned int or size_t, to count bits.

(lbitset_bytes): Use size_t, not unsigned int, to count bytes.
Use proper printf formats for widths of integer types.

(lbitset_ones, lbitset_not): Use bitset_windex instead of unsigned int.

(lbitset_elt_find): Simplify windex calculation and avoid cast to unsigned.
2002-10-02 08:00:19 +00:00
Paul Eggert
effda851f6 (ebitset_bytes): Use size_t, not unsigned int, to count bytes. 2002-10-02 07:58:11 +00:00
Paul Eggert
52f8da14ea (ebitset_size, ebitset_list, ebitset_list_reverse):
Use bitset_bindex, not int or unsigned int or size_t, to count bits.

(ebitset_bytes): Use size_t, not unsigned int, to count bytes.

(struct ebitset_struct.size, ebitset_elts_grow,
ebitset_elt_add, ebitset_elt_remove, ebitset_weed,
ebitset_elt_find, ebitset_list_reverse, ebitset_list, ebitset_init):
Use bitset_windex instead of unsigned int.

(ebitset_elts_grow): Check for arithmetic overflow when computing sizes.
2002-10-02 07:57:24 +00:00
Paul Eggert
eb6172cd1e (bitsetv_alloc, bitsetv_create):
Use bitset_bindex, not int or unsigned int or size_t, to count bits.
2002-10-02 07:55:44 +00:00