summaryrefslogtreecommitdiff
path: root/NEWS
diff options
context:
space:
mode:
authorAkim Demaille <akim.demaille@gmail.com>2018-12-10 17:41:24 +0100
committerAkim Demaille <akim.demaille@gmail.com>2018-12-10 17:50:12 +0100
commit81dbd0d82e5812d620bc16184583df10b1738cee (patch)
tree731f5687017ccc320a290d9ab8d5b0155eb807c9 /NEWS
parentd657da9fb40e961401069c3767bb12902c2faec1 (diff)
downloadbison-81dbd0d82e5812d620bc16184583df10b1738cee.tar.gz
C++: support variadic emplace
Suggested by Askar Safin. http://lists.gnu.org/archive/html/bug-bison/2018-12/msg00006.html * data/variant.hh: Implement. * tests/types.at: Check. * doc/bison.texi: Document.
Diffstat (limited to 'NEWS')
-rw-r--r--NEWS16
1 files changed, 16 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index 3b714d6a..5f23fa79 100644
--- a/NEWS
+++ b/NEWS
@@ -100,6 +100,22 @@ GNU Bison NEWS
until it sees the '='. So we notate the two possible reductions to
indicate that each conflicts in one rule.
+*** C++: Variadic emplace
+
+ If your application requires C++11, you may now use a variadic emplace for
+ semantic values:
+
+ %define api.value.type variant
+ %token <std::pair<int, int>> PAIR
+
+ in your scanner:
+
+ int yylex (parser::semantic_type *lvalp)
+ {
+ lvalp->emplace <std::pair<int, int>> (1, 2);
+ return parser::token::PAIR;
+ }
+
*** More POSIX Yacc compatibility warnings
More Bison specific directives are now reported with -y or -Wyacc. This