X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/26f95f5f356ca003d125a5c5285a09a0564e3bd9..ddb9db151b1620a2bffceeddf7790dd586129d92:/data/c%20%20.m4/bison.git/blobdiff_plain/26f95f5f356ca003d125a5c5285a09a0564e3bd9..ddb9db151b1620a2bffceeddf7790dd586129d92:/data/c++.m4 diff --git a/data/c++.m4 b/data/c++.m4 index e91b90d7..87bc5e0d 100644 --- a/data/c++.m4 +++ b/data/c++.m4 @@ -231,6 +231,8 @@ m4_define([b4_public_types_declare], /// The token. token_type token () const; + enum { empty = 0 }; + /// The symbol type. /// /// -1 when this symbol is empty. @@ -328,7 +330,7 @@ m4_define([b4_public_types_define], // by_type. inline ]b4_parser_class_name[::by_type::by_type () - : type (-1) + : type (empty) {} inline @@ -346,7 +348,7 @@ m4_define([b4_public_types_define], ]b4_parser_class_name[::by_type::move (by_type& that) { type = that.type; - that.type = -1; + that.type = empty; } inline