Commit Graph

296 Commits

Author SHA1 Message Date
Akim Demaille 79e79be298 diagnostics: improve accuracy for deprecated %define variables
* src/parse-gram.y: Use the location of the whole definition to record
the location of a %define variable, instead of just the name of the
variable.
Adjust tests.
2019-01-14 19:57:37 +01:00
Akim Demaille 8c3a7687e4 regen 2019-01-14 19:57:37 +01:00
Akim Demaille dbe499e936 regen 2018-12-16 12:27:28 +01:00
Akim Demaille 4cbdcaa572 regen 2018-12-09 13:55:05 +01:00
Akim Demaille 1e6a68858a regen 2018-12-09 12:50:53 +01:00
Akim Demaille f539a56620 regen 2018-12-03 18:42:00 +01:00
Akim Demaille 060da943bd regen 2018-11-30 06:10:21 +01:00
Akim Demaille b1d6c42ae5 regen 2018-11-29 06:16:20 +01:00
Akim Demaille 0e9eade009 regen 2018-11-27 08:32:49 +01:00
Akim Demaille 9ffed56cd9 regen 2018-11-25 11:27:08 +01:00
Akim Demaille 4ebebcc438 regen 2018-11-21 22:10:35 +01:00
Akim Demaille ebb92c0545 regen 2018-11-20 20:04:06 +01:00
Akim Demaille 4810ed8107 regen 2018-11-12 07:41:46 +01:00
Akim Demaille 3d601616da regen 2018-11-10 17:03:36 +01:00
Akim Demaille 0308dfb039 regen 2018-10-23 09:08:57 +02:00
Akim Demaille a7842d1bc0 regen 2018-10-21 09:58:44 +02:00
Akim Demaille 9017924783 regen 2018-10-16 13:41:45 +02:00
Akim Demaille a99b4f45bb regen 2018-10-16 13:33:32 +02:00
Akim Demaille d288047e9b regen 2018-08-18 07:42:07 +02:00
Akim Demaille c2de9dafd1 regen 2018-08-14 06:15:42 +02:00
Akim Demaille 9502b2ab48 style: split a function in two
grammar_current_rule_action_append was used in two different places:
for actual action (`{...}`), and for predicates (`%?{...}`).  Let's
split this in two different functions.

* src/reader.h, src/reader.c (grammar_current_rule_predicate_append): New.
Extracted from...
(grammar_current_rule_action_append): here.
Remove arguments that don't apply.
Adjust dependencies.
2018-07-26 20:18:32 +02:00
Akim Demaille 4eeec4e41f regen 2018-05-27 10:46:31 +02:00
Akim Demaille 77a0e35143 regen 2018-05-19 15:14:46 +02:00
Akim Demaille 827bc59ca1 %union: fix the support for named %union
Bison supports a union tag, for obscure reasons.  But it does a poor
job at it, especially since Bison 3.0.
Reported by Stephen Cameron and Tobias Frost.

It did not ensure that the name was not given several times.  An easy
way to do this is to make the %union tag be handled as a %define
variable, as they cannot be defined several times.

Since Bison 3.0, the synclines were wrongly placed, resulting in
invalid code.  Addressing this issue, because of the way the union tag
was stored (as a code muscle), would have been tedious.  Unless we
rather define the %union tag as a %percent variable, whose synclines
are easier to manipulate.

So replace the b4_union_name muscle by the api.value.union.name
%define variable, document, and check.

* data/bison.m4: Make sure that api.value.union.name has a keyword value.
* data/c++.m4: Make sure that api.value.union.name is not defined.
* data/c.m4 (b4_union_name): No longer use it, use api.value.union.name.
* doc/bison.texi (%define Summary): Document it.
* src/parse-gram.y (union_name): No longer define b4_uion_name, but
api.value.union.name.
* tests/input.at (Redefined %union name): New.
* tests/synclines.at (%union name syncline): New.
* tests/types.at: Check named %unions.
2015-01-04 18:00:51 +01:00
Akim Demaille 3209eb1c4c package: bump to 2015
Which also requires:

* gnulib: Update.
2015-01-04 17:49:13 +01:00
Akim Demaille a62a7b014c regen 2013-07-25 17:55:32 +02:00
Akim Demaille c0ef22ab0b style: syntax-check fixes
* data/yacc.c, src/Sbitset.c, src/Sbitset.h, src/muscle-tab.h,
* src/output.c, src/parse-gram.y, src/reader.c, src/symtab.c,
* src/uniqstr.c, src/uniqstr.h: Fix space before parens.
* cfg.mk (_space_before_paren_exempt): Add needed exceptions.
2013-05-30 14:10:05 +02:00
Akim Demaille e37054cf27 regen 2013-05-30 11:07:56 +02:00
Akim Demaille 332019e19a regen 2013-04-18 16:47:41 +02:00
Akim Demaille 7dbadca2d0 regen 2013-04-18 15:12:24 +02:00
Akim Demaille ff2e3d397a regen 2013-04-16 18:06:08 +02:00
Akim Demaille de5fb744c9 regen 2013-04-04 16:50:55 +02:00
Akim Demaille 8a9283494b regen 2013-04-04 15:48:08 +02:00
Akim Demaille 2dc8862bab regen 2013-03-06 10:31:55 +01:00
Akim Demaille bbed3fdef6 regen 2013-02-19 10:07:37 +01:00
Akim Demaille 8ecac08f2d regen 2013-02-18 10:01:27 +01:00
Akim Demaille 246ff8c1d3 regen 2013-02-04 16:49:10 +01:00
Akim Demaille 74ce3cfbf6 regen 2013-02-01 14:26:29 +01:00
Akim Demaille c6a731eebb regen 2013-01-27 10:41:16 +01:00
Akim Demaille 3f4bc2c1dd regen 2013-01-12 16:23:16 +01:00
Akim Demaille 0904099dd5 regen 2012-12-28 11:37:22 +01:00
Akim Demaille 258b45c86b regen 2012-12-28 11:37:21 +01:00
Akim Demaille 0a9042a652 regen 2012-12-27 10:33:46 +01:00
Akim Demaille 369342dd3a regen 2012-11-08 09:35:59 +01:00
Akim Demaille 8d9cffffed regen 2012-10-26 16:59:04 +02:00
Theophile Ranquet 25b27513d9 regen 2012-10-24 14:50:21 +00:00
Theophile Ranquet bb8e56ff67 warnings: fusion of complain and complain_at
These functions are very similar, and keeping them seperate makes
future improvements difficult, so merge them.

This impacts 89 calls.

* src/bootstrap.conf: Adjust.
* src/complain.c (complain, complain_at): Merge into...
(complain): this.
(complain_args): Adjust.
* src/complain.h, src/conflicts.c, src/files.c, src/getargs.c,
* src/gram.c, src/location.c, src/muscle-tab.c, src/parse-gram.y,
* src/reader.c, src/reduce.c, src/scan-code.l, src/scan-gram.l,
* src/scan-skel.l, src/symlist.c, src/symtab.c:
Adjust.

Signed-off-by: Akim Demaille <akim@lrde.epita.fr>
2012-10-01 14:15:47 +02:00
Akim Demaille 37cfa1195d regen 2012-09-26 12:20:44 +02:00
Akim Demaille 47f6a236ec regen 2012-09-04 18:53:45 +02:00
Akim Demaille 52cc1ebda2 regen 2012-08-03 11:09:22 +02:00