Commit Graph

363 Commits

Author SHA1 Message Date
Josh Soref
57e3f5a80c spelling: enum 2018-10-05 07:01:04 +02:00
Akim Demaille
8d64416e8c gnulib: update 2018-10-05 06:14:20 +02:00
Akim Demaille
f84a8e96d1 gnulib: move timevar to it
* lib/timevar.c, lib/timevar.h, m4/timevar.m4: Remove.
* gnulib: Update.
* configure.ac: Adjust.
* lib/timevar.def: Use lower case for the timevvars.
Adjust dependencies.
2018-09-30 14:19:53 +02:00
Akim Demaille
a990213582 timevar: don't declare getrusage if we don't use it
This fails on MinGW.
Reported by Simon Sobisch.
http://lists.gnu.org/archive/html/bug-bison/2018-09/msg00058.html

* lib/timevar.c: Don't provide default prototypes for functions
we don't use.
2018-09-22 15:58:27 +02:00
Akim Demaille
9dfd46a5d5 timevar: get rid of a useless macro
* lib/timevar.h (timevar_report): Rename as...
(timevar_enabled): this.
* lib/timevar.c (TIMEVAR_ENABLE): Remove.
2018-09-22 15:58:27 +02:00
Akim Demaille
984d8cc72c timevar: introduce and use get_current_time
* lib/timevar.c: here.
Remove useless prototypes.
(timevar_accumulate): Be const correct.
2018-09-22 15:58:27 +02:00
Akim Demaille
896b2f75c5 timevar: rename get_time as set_to_current_time
* lib/timevar.c: here.
2018-09-22 15:58:27 +02:00
Akim Demaille
3ce67fa673 timevar: reduce scopes
* lib/timevar.c: here.
2018-09-22 15:58:27 +02:00
Akim Demaille
889dea0275 timevar: document in the header, not in the implementation
* lib/timevar.c: Move documentation from here...
* lib/timevar.h: to there.
2018-09-22 15:58:27 +02:00
Akim Demaille
ab3ec56ffe timevar: remove useless 'extern' for prototypes
* lib/timevar.h, lib/timevar.c: here.
2018-09-22 15:58:27 +02:00
Akim Demaille
c8da23c372 timevar: rename init_timevar as timevar_init
* lib/timevar.h, lib/timevar.c: here.
* src/main.c: Adjust.
2018-09-22 15:58:27 +02:00
Akim Demaille
69720f1231 timevar: we don't care about backward compatibility
* lib/timevar.h, lib/timevar.c (get_run_time, print_time): Remove.
2018-09-22 15:58:27 +02:00
Akim Demaille
100f8696c7 timevar: prefer #elif
* lib/timevar.c: Use #if/#elif to be clearer about mutually exclusive
cases.
Indent CPP nested directives.
2018-09-22 15:58:27 +02:00
Akim Demaille
8c6b06df1f timevar: assume ANSI C
Suggested by Bruno Haible.
https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00102.html

* lib/timevar.c: Wow...  This was still KnR C!
2018-09-22 15:58:27 +02:00
Akim Demaille
6d9aafc5ad timevar: remove remains of GCC
* lib/timevar.h, lib/timevar.c: Rename the header guard.
Get rid of parts meant for GCC only.
2018-09-22 15:58:27 +02:00
Akim Demaille
9df53e7288 style: lib: remove useless reference to 'int' in integral types
* lib/abitset.c, lib/bbitset.h, lib/bitset.c, lib/bitset.h,
* lib/bitset_stats.c, lib/bitsetv-print.c, lib/bitsetv.c,
* lib/bitsetv.h, lib/ebitset.c, lib/lbitset.c, lib/timevar.c,
* lib/vbitset.c:
Prefer 'unsigned' to 'unsigned int'.  Likewise for long and short.
2018-08-14 06:15:41 +02:00
Akim Demaille
d03ad8b686 gnulib: update
Fixes the `make install-pdf` problem reported by Hans Åberg in
http://lists.gnu.org/archive/html/bug-bison/2018-06/msg00000.html
that had already been fixed by Joel E. Denny in
http://lists.gnu.org/archive/html/bug-bison/2012-04/msg00011.html
Final fix in
http://lists.gnu.org/archive/html/bug-gnulib/2018-06/msg00019.html
2018-06-18 07:13:28 +02:00
Akim Demaille
2e9e591889 Update copyright years
Run `make update-copyright`.
2018-05-12 18:18:41 +02:00
Akim Demaille
76bd8a6b4a gnulib: update
* README-hacking: Commit before bootstrapping.
* bootstrap.conf: gnulib_mk is no longer defined by bootstrap.
* bootstrap, gnulib, lib/.gitignore, m4/.gitignore: Update/regen.
2018-05-08 12:35:06 +02:00
Paul Eggert
4b314bdb6d Adjust to recent Gnulib changes 2017-09-16 21:58:07 -07:00
Akim Demaille
88ffc4b907 gnulib: strtoul is considered obsolete and now useless
* bootstrap.conf: here.
2015-01-15 17:26:32 +01:00
Akim Demaille
3209eb1c4c package: bump to 2015
Which also requires:

* gnulib: Update.
2015-01-04 17:49:13 +01:00
Akim Demaille
179b2419ba gnulib: update 2014-12-29 16:13:57 +01:00
Akim Demaille
fc51acddb4 package: bump to 2014
* AUTHORS, ChangeLog-2012, Makefile.am, NEWS, PACKAGING, README,
* README-alpha, README-hacking, THANKS, TODO, bootstrap.conf,
* build-aux/darwin11.4.0.valgrind, build-aux/local.mk,
* build-aux/update-b4-copyright,
* build-aux/update-package-copyright-year, cfg.mk, configure.ac,
* data/README, data/bison.m4, data/c++-skel.m4, data/c++.m4,
* data/c-like.m4, data/c-skel.m4, data/c.m4, data/glr.c, data/glr.cc,
* data/java-skel.m4, data/java.m4, data/lalr1.cc, data/lalr1.java,
* data/local.mk, data/location.cc, data/stack.hh, data/variant.hh,
* data/xslt/bison.xsl, data/xslt/xml2dot.xsl, data/xslt/xml2text.xsl,
* data/xslt/xml2xhtml.xsl, data/yacc.c, djgpp/Makefile.maint,
* djgpp/README.in, djgpp/config.bat, djgpp/config.sed,
* djgpp/config.site, djgpp/config_h.sed, djgpp/djunpack.bat,
* djgpp/local.mk, djgpp/subpipe.c, djgpp/subpipe.h,
* djgpp/testsuite.sed, doc/bison.texi, doc/local.mk, doc/refcard.tex,
* etc/README, etc/bench.pl.in, etc/local.mk,
* examples/calc++/calc++.test, examples/calc++/local.mk,
* examples/extexi, examples/local.mk, examples/mfcalc/local.mk,
* examples/mfcalc/mfcalc.test, examples/rpcalc/local.mk,
* examples/rpcalc/rpcalc.test, examples/test, examples/variant.yy,
* lib/abitset.c, lib/abitset.h, lib/bbitset.h, lib/bitset.c,
* lib/bitset.h, lib/bitset_stats.c, lib/bitset_stats.h,
* lib/bitsetv-print.c, lib/bitsetv-print.h, lib/bitsetv.c,
* lib/bitsetv.h, lib/ebitset.c, lib/ebitset.h, lib/get-errno.c,
* lib/get-errno.h, lib/lbitset.c, lib/lbitset.h, lib/libiberty.h,
* lib/local.mk, lib/main.c, lib/timevar.c, lib/timevar.def,
* lib/timevar.h, lib/vbitset.c, lib/vbitset.h, lib/yyerror.c,
* m4/bison-i18n.m4, m4/c-working.m4, m4/cxx.m4, m4/flex.m4,
* m4/timevar.m4, src/AnnotationList.c, src/AnnotationList.h,
* src/InadequacyList.c, src/InadequacyList.h, src/LR0.c, src/LR0.h,
* src/Sbitset.c, src/Sbitset.h, src/assoc.c, src/assoc.h,
* src/closure.c, src/closure.h, src/complain.c, src/complain.h,
* src/conflicts.c, src/conflicts.h, src/derives.c, src/derives.h,
* src/files.c, src/files.h, src/flex-scanner.h, src/getargs.c,
* src/getargs.h, src/gram.c, src/gram.h, src/graphviz.c,
* src/graphviz.h, src/ielr.c, src/ielr.h, src/lalr.c, src/lalr.h,
* src/local.mk, src/location.c, src/location.h, src/main.c,
* src/muscle-tab.c, src/muscle-tab.h, src/named-ref.c,
* src/named-ref.h, src/nullable.c, src/nullable.h, src/output.c,
* src/output.h, src/parse-gram.c, src/parse-gram.y, src/print-xml.c,
* src/print-xml.h, src/print.c, src/print.h, src/print_graph.c,
* src/print_graph.h, src/reader.c, src/reader.h, src/reduce.c,
* src/reduce.h, src/relation.c, src/relation.h, src/scan-code.h,
* src/scan-code.l, src/scan-gram.h, src/scan-gram.l, src/scan-skel.h,
* src/scan-skel.l, src/state.c, src/state.h, src/symlist.c,
* src/symlist.h, src/symtab.c, src/symtab.h, src/system.h,
* src/tables.c, src/tables.h, src/uniqstr.c, src/uniqstr.h,
* tests/actions.at, tests/atlocal.in, tests/bison.in, tests/c++.at,
* tests/calc.at, tests/conflicts.at, tests/cxx-type.at,
* tests/existing.at, tests/glr-regression.at, tests/headers.at,
* tests/input.at, tests/java.at, tests/javapush.at, tests/local.at,
* tests/local.mk, tests/named-refs.at, tests/output.at, tests/push.at,
* tests/reduce.at, tests/regression.at, tests/sets.at,
* tests/skeletons.at, tests/synclines.at, tests/testsuite.at,
* tests/torture.at, tests/types.at:
here.
2014-02-03 15:27:02 +01:00
Akim Demaille
a4122000c6 gnulib: update
* gnulib: here.
2013-12-05 14:42:08 +01:00
Akim Demaille
265640d56e install: do not install yacc.1 when --disable-yacc
* configure.ac (ENABLE_YACC): New conditional.
(YACC_SCRIPT, YACC_LIBRARY): Remove.
* lib/local.mk, src/local.mk: Use the former instead of the latter.
* doc/local.mk: Use ENABLE_YACC to avoid installing yacc.1.
2013-10-22 17:34:22 +02:00
Akim Demaille
4c9b8f1318 style: no longer use backquotes
* tests/actions.at, tests/atlocal.in, tests/c++.at, tests/calc.at,
* tests/conflicts.at, tests/existing.at, tests/glr-regression.at,
* tests/input.at, tests/java.at, tests/local.at, tests/sets.at,
* tests/synclines.at, doc/bison.texi, lib/libiberty.h, lib/timevar.h:
Use single quotes.
2013-02-18 10:01:28 +01:00
Akim Demaille
7d6bad1959 maint: update copyright years
Suggested by Stefano Lattarini.
Run "make update-copyright".
2013-01-12 16:14:16 +01:00
Akim Demaille
bcf54c336e regen 2013-01-09 16:41:16 +01:00
Theophile Ranquet
432a008d34 carets: properly display when no line feed is present
* src/location.c (location_caret): finish the line with one whether or not it
is present in input. Rewrite code without getline.
(cleanup_caret): Reset the caret_info global.
* bootstrap.conf: No longer require getline.
2012-12-27 17:57:03 +01:00
Akim Demaille
7c0d37283d gnulib: update 2012-12-19 11:30:22 +01:00
Akim Demaille
50977317cd tests: address syntax-check failures
* cfg.mk: Ignore failures in timevar (uses GCC style configuration,
not gnulib's).
* doc/local.mk: Space changes.
* lib/main.c, tests/calc.at: Remove useless HAVE_ tests.
2012-12-16 10:33:42 +01:00
Theophile Ranquet
f3ead217b8 Merge remote-tracking branch 'origin/maint'
* origin/maint:
  misc: pacify the Tiny C Compiler
  cpp: make the check of Flex version portable
  misc: require getline
  c++: support wide strings for file names
  doc: document carets
  tests: enhance existing tests with carets
  errors: show carets
  getargs: add support for --flags/-f

Conflicts:
	doc/bison.texi
	m4/.gitignore
	src/complain.c
	src/flex-scanner.h
	src/getargs.c
	src/getargs.h
	src/gram.c
	src/main.c
	tests/headers.at
2012-12-06 13:38:43 +01:00
Theophile Ranquet
e35cd6def7 misc: require getline
* bootstrap.conf: Here, used by src/location.c.
* src/getargs.c (long_options): Rename --flags to --feature.
2012-12-05 15:39:52 +01:00
Akim Demaille
064e42b0ac Merge remote-tracking branch 'origin/maint'
* origin/maint:
  parser: accept #line NUM
  m4: use a safer pattern to enable/disable output
  tests: beware of gnulib's need for config.h
  gnulib: update
  yacc.c, glr.c: check and fix the display of locations
  formatting changes
  glr.c: remove stray macro

Conflicts:
	data/c.m4
	data/glr.cc
	data/lalr1.cc
	data/lalr1.java
	data/location.cc
	data/stack.hh
	data/yacc.c
	src/scan-gram.l
2012-12-03 16:27:23 +01:00
Akim Demaille
8aef6e0db5 gnulib: update
* lib/yyerror.c: Include config.h since the following stdio.h might be
from gnulib.
2012-11-30 12:37:34 +01:00
Akim Demaille
6c05543cb0 Merge remote-tracking branch 'origin/maint'
* origin/maint:
  regen
  yacc: fix handling of CPP guards when no header is generated
  gnulib: update
2012-09-26 12:19:15 +02:00
Akim Demaille
53425dbfaa gnulib: update 2012-09-25 10:24:36 +02:00
Akim Demaille
cb9ec4fada Merge branch 'maint'
* maint:
  use obstack_printf
  scanner: restore a missing start condition
  gnulib: update
  maint: post-release administrivia
  version 2.6.1
  gnulib: update
  maint: fix some syntax-check issues
  tests: do not depend on __cplusplus to decide for C++ or C output

Conflicts:
	NEWS
	bootstrap.conf
	cfg.mk
	lib/.gitignore
2012-07-31 12:03:55 +02:00
Akim Demaille
aaf63e45b6 use obstack_printf
This is not just nicer, it is also much safer, since we were
using sprintf...

* bootstrap.conf: Require it.
* src/system.h (obstack_fgrow1, obstack_fgrow2, obstack_fgrow3)
(obstack_fgrow4): Remove.
Adjust dependencies.
2012-07-31 10:50:06 +02:00
Akim Demaille
297e263a00 Merge remote-tracking branch 'origin/maint'
* origin/maint:
  tests: do not output m4 set up.
  tests: use the generic yyerror function.
  tests: use assert instead of plain abort.
  tests: improve the generic yylex implementation.
  tests: generalize the compilation macros.
  tests: fix confusion between api.prefix and name-prefix.
  maint: gitignores.
  yacc: work around the ylwrap limitation.

Conflicts:
	NEWS
	tests/local.at
2012-06-26 16:44:59 +02:00
Akim Demaille
5e01579ec0 maint: gitignores. 2012-06-26 13:55:49 +02:00
Akim Demaille
84526bf3d1 maint: don't use mbsr?chr.
Basically, revert ba60c39547a445dee3e07920931b4d7a81843868's move to
mbs* functions, which was prompted by -DGNULIB_POSIXCHECK.  See
<http://lists.gnu.org/archive/html/bison-patches/2012-05/msg00052.html>
and following.

* bootstrap.conf: No longer ask for them.
* src/files.c, src/getargs.c, src/location.c,
* src/parse-gram.c, src/parse-gram.y, src/scan-gram.l,
* src/symtab.c: s/mbs(r?chr)/str$1/g.
2012-06-05 17:55:24 +02:00
Akim Demaille
d9a7c07c5a maint: use xconcat-filename.
* bootstrap.conf (gnulib_modules): Request it.
* src/output.h, src/output.c (compute_pkgdatadir): Rename as...
(pkgdatadir): this.
Adjust dependencies.
* src/output.c (output_skeleton): Reduce the scope of "in".
Use xconcatenated_filename to simplify the construction of the
qualified paths to m4sugar.m4, bison.m4, and the selected skeleton.
There are a few minor differences: the new code uses strchr instead of
mbschr (but this was not really justified), and the new code does not
garantee a single slash even if $BISON_PKGDATADIR ends with several
(which was considered more accurate).  See the discussion at
<http://lists.gnu.org/archive/html/bison-patches/2012-05/msg00052.html>.
2012-06-05 17:34:57 +02:00
Akim Demaille
c547693afd Merge tag 'v2.5.1_rc2'
Bison 2.5.1_rc2.

* tag 'v2.5.1_rc2': (34 commits)
  Bison 2.5.1_rc2.
  doc: fixes.
  build: fix ChangeLog generation.
  c++: compute the header guards.
  skeletons: remove support for unused directive.
  lalr1.cc: improve Doxygen documentation.
  lalr1.cc: extract stack.hh.
  news: convert to double quotes.
  space changes.
  build: do not prototype flex-generated functions.
  build: fix ChangeLog generation.
  Bison 2.5.1_rc1.
  tests: save/restore Autotest special files when checking XML support.
  tests: AT_SAVE_SPECIAL_FILES / AT_RESTORE_SPECIAL_FILES.
  tests: honor TESTSUITEFLAGS in all the check targets.
  build: do not enable c++ warnings on 0 when nullptr is not supported.
  maint: update gnulib.
  build: config.in.h.
  build: move silent rules.
  glr.c: reduce variable scopes.
  maint: maintainer-release-check.
  maint: shush a syntax-check.
  maint: prefer "commit message" to "log entry".
  command line: fix minor leaks.
  maint: we no longer maintain the ChangeLog.
  maint: fix the generation of the synclines for bison's parser.
  maint: regen.
  maint: import the xmemdup0 gnulib module.
  maint: remove left-over gnulib modules.
  maint: ignore files imported by autopoint.
  build: AC_PROG_LEX: use more readable variable names.
  maint: regen src/parse-gram.[ch]
  maint: simplify parse-gram.y
  maint: s/strncpy/memcpy/, when equivalent

Conflicts:
	Makefile.am
	NEWS
	data/glr.c
	data/lalr1.cc
	data/stack.hh
	examples/rpcalc/local.mk
	src/flex-scanner.h
	src/getargs.c
	src/output.c
	src/parse-gram.c
	src/parse-gram.h
	src/parse-gram.y
	tests/Makefile.am
	tests/bison.in
2012-05-24 13:54:55 +02:00
Akim Demaille
b2c4c25d4a maint: update gnulib.
* bootstrap, gnulib: Update.
2012-05-11 09:26:09 +02:00
Akim Demaille
91fd2b60b6 build: config.in.h.
Historically we used config.hin (where everybody else used
config.h.in) to please DOS.  Now that we use gnulib, there are already
tons of files with several dots, especially *.in.h.

* configure.ac: Rename config.hin as config.in.h.
2012-05-09 11:21:34 +02:00
Akim Demaille
e54ec80c0c maint: import the xmemdup0 gnulib module.
* bootstrap.conf: Require this module.
* src/parse-gram.y: Include xmemdup0.h.
2012-05-06 10:20:43 +02:00
Akim Demaille
85557aa1cb maint: remove left-over gnulib modules.
* bootstrap.conf (gnulib_modules): Remove pipe-posix.
* lib/.gitignore, m4/.gitignore: Remove files that we no longer use.
2012-05-06 10:08:18 +02:00
Akim Demaille
3e75a2c92b Merge remote-tracking branch 'origin/maint'
* origin/maint:
  bump to 2012 in skeletons.
  build: remove ancient Autoconf tests.
  doc: c++: complete the location documentation.
  c++: locations: provide convenience constructors.
  c++: locations: remove useless "inline".
  glr: do not use locations when they are not requested
  c++: use nullptr for C++11.
  build: simplify and improve the compiler warnings for tests.
  gnulib: update.
  maint: formatting changes.
  NEWS: update.
  Java: Fix syntax error handling without error token.
  tests: beware of -pedantic on large #line numbers.
  tests: when using the C++ compiler, use its flags too.

Conflicts:
	data/glr.c
	data/glr.cc
	data/lalr1.cc
	data/location.cc
	data/yacc.c
	tests/Makefile.am
2012-04-01 13:14:34 +02:00